Info

Login

Channels

APIs

Credits

  • cheeser
  • ernimril
  • joed
  • kinabalu
  • lunk
  • ojacobson
  • r0bby
  • ThaDon
  • ricky_clarkson
  • topriddy

« 2015-08-02

2015-08-03

2015-08-04 »

Nick Message Date
jelmd [port-ip-88-150-13-159.reverse.mdcc-fun.de] has joined #glassfish [12:49]
jelmd [port-ip-88-150-13-159.reverse.mdcc-fun.de] has joined #glassfish [01:01]
CJ_ [unaffiliated/cj-/x-2232545] has joined #glassfish [06:08]
sarri [unaffiliated/sarri] has joined #glassfish [06:16]
yeitijem [p50995cae.dip0.t-ipconnect.de] has joined #glassfish [06:18]
edburns [inet-hqmc08-o.oracle.com] has joined #glassfish [01:27]
whartung wierdest thing. I think we have a JSP Tag file "holding on" to its arguments [04:41]
whartung just seeing weird memory leaks and currently the references are all within the JSP tags [04:42]
whartung both tag files and JSTL tags [04:42]
_Tenchi_ i remember seeing something like that a long time ago when porting some apps from tomcat to glassfish [05:03]
_Tenchi_ it turned out to be something with the tomcat apps including standard tag jars in the webapps [05:03]
whartung yea I'd do;t think we're doing that... [05:03]
whartung but we see this list growing, with stuff, but it's not being held on to by the session, or a static of our own. [05:05]
whartung and the thing is [05:05]
whartung we use these tags every where, all the time, and have never seen anything like this, so I'm loathe to "blame the container". [05:06]
whartung I'm tracing them with jmap dumps and jhat [05:06]
_Tenchi_ whartung: have to be careful with maven in that respect... sometimes a new dependency will have some transitive depency that'll fail to declare something as already being provided [05:08]
whartung sure [05:08]
whartung <3 maven. Makes my heart go pitter pat. [05:08]
_Tenchi_ every time a dependency gets updated... have to check to make sure the depency tree that it brings along with isn't broken [05:09]
whartung as you start digging you get in to a lot of "maps of maps" which makes deciphering things really awful [05:10]
whartung this is the one that bothers me [05:11]
whartung com.sun.enterprise.container.common.impl.managedbean.ManagedBeanManagerImpl@0x781d4bab8 (96 bytes) : field jcdiManagedBeanInstanceMap [05:11]
whartung have you ever used weak references? Those are an actual instance right? [05:15]
whartung Like you'd have a List with a WeakReference instance that points to your item [05:15]
whartung I've never used them [05:15]
_Tenchi_ yeah i use weak references [05:29]
_Tenchi_ whatever they point to is eligible for garbage collection [05:30]
_Tenchi_ if there is pressure for memory, GC can null out the weak reference and GC whatever it was pointing to if there are no other hard references to the instance [05:32]
whartung how aggressive is that? do they get zapped on incrmentals or just full GCs? [05:33]
_Tenchi_ both [05:33]
_Tenchi_ they can get zapped at any time... it's up to the collection algorithm [05:34]
whartung yea [05:34]
whartung when do you use them? Just seems to be they'd get zapped early and often [05:34]
_Tenchi_ yeah it depends on the pressure [05:34]
_Tenchi_ i use them usually when i'm doing a lot of data streaming [05:35]
_Tenchi_ when i have items to validate against, for example [05:35]
whartung that's why I never really explored them, they just seem utterly unreliable. [05:35]
whartung you use them on fairly coarse objects I would think? [05:36]
_Tenchi_ when im processing a lot of data, and i want to trade off free memory for cpu processing [05:36]
_Tenchi_ i'll use them as like a "maybe" cache :) [05:36]
whartung yea [05:36]
_Tenchi_ if it's cheaper to hold something in memory than search for it w/ processing power, for example [05:36]
whartung of course [05:37]
whartung makes it so when you system is under pressue its even more slow than normal lol [05:37]
_Tenchi_ hehe yeah [05:37]
whartung so I'm thinking this is jsp tag caching [05:38]
whartung which we've used for, like, ever. [05:38]
whartung but I guess it's just extra ugly with what we're doing in this thing [05:38]
_Tenchi_ maybe think of it as a thread local... [05:40]
_Tenchi_ check for null first... and then do something if it's null to load/initialize it [05:40]
_Tenchi_ if it's not null... then it's ready to use [05:40]
_Tenchi_ the reference won't be reliable in that you need to check to see if it's null [05:41]
whartung yea [05:41]
whartung only on a Mac can an IRC program consume 1G of ram [05:42]
_Tenchi_ hah [05:42]
whartung brb sec [05:44]
whartung [wsip-70-183-27-154.oc.oc.cox.net] has joined #glassfish [05:46]
whartung back [05:46]
whartung 42M now lol [05:46]
whartung I need to read this, and the links, this looks interesting [05:50]
whartung https://dzone.com/articles/is-asynchronous-ejb-just-a-gimmick [05:50]
whartung and?.my jhat is getting stuck?"thanks a lot" [05:52]
whartung busy busy busy https://www.dropbox.com/s/idfhc7w47vhywnb/Screenshot%202015-08-03%2014.53.11.png?dl=0 [05:53]
javabot whartung's title: Dropbox - Screenshot 2015-08-03 14.53.11.png [05:53]
pdurbin whartung: low cpu usage, looks like [06:12]
whartung still seems to be pooling jsp tags... [06:31]
whartung I guess GF 3 uses raw JspC from Apache [06:58]
pdurbin whartung: that article does look interesting. Is it all true? [07:02]
whartung dunno -- I haven't read it yet :) [07:02]
pdurbin ok. please keep me posted :) [07:03]
pdurbin _Tenchi_: what do you think? [07:04]
_Tenchi_ pdurbin: it's a big topic but I wouldn't call it a "gimick" [07:24]
_Tenchi_ i think we had a discussion about this a few years ago [07:24]
_Tenchi_ I think with dmlloyd [07:24]
_Tenchi_ heh [07:25]
_Tenchi_ i just skimmed the article and it touches on a few things, but it fails to take into account that transactions are bound to threads [07:25]
whartung I think the headline is hyperbole (NO!) [07:25]
_Tenchi_ but yeah, the async ejb functionality is pretty limited in places where you'd want to use it [07:25]
whartung I was mostly interested in the "thread sleep is slow" details that's likely more detailed in teh linked articles [07:25]
whartung because that's his complaint [07:26]
_Tenchi_ managed executor service is a lt more useful [07:26]
whartung async ejb sucks because it uses sleep [07:26]
whartung "oh" [07:26]
whartung "k" [07:26]
_Tenchi_ well... [07:26]
_Tenchi_ polling for async results sucks [07:26]
whartung well, some one, somewhere has to poll :) [07:26]
_Tenchi_ you wanna use callbacks to the greatest extend possible... but with aync ejb it's limited [07:26]
whartung sure [07:26]
whartung but then how old is async ejb? 5 years now? worlds changed a wee bit [07:27]
_Tenchi_ the's essentially "the problem" but it is what it is... it's stupid to write long ass articles about it rather than try to engage the expert groups and talk their ears off about the correct way to do things [07:27]
_Tenchi_ yeah i think async ejb was jee6 [07:27]
_Tenchi_ and managed executor service is jee7 [07:27]
whartung talking on another channel about JEE 8 and JSON support -- and how the json jsr doesn't even do binding. That's a different JSR that won't even be final on the spec until 2017 [07:28]
_Tenchi_ haha yeah [07:28]
_Tenchi_ but json binding is a hairy thing [07:28]
_Tenchi_ just like xml binding is hairy [07:29]
_Tenchi_ and orm [07:29]
whartung oh yea, of course [07:30]
whartung you' dlike to think it would be a wee bit less hairy with JAX-B to bounce off of, but?who knows [07:30]
_Tenchi_ yeah, limited facility hehe [07:31]
_Tenchi_ w/o binding [07:31]
whartung yea [07:31]
_Tenchi_ but hey, eclipselink is the default reference impl for jpa [07:32]
_Tenchi_ and they have Moxy [07:32]
_Tenchi_ dunno if that was the reference impl for xml binding... but it now does json binding [07:32]
_Tenchi_ and is the default provider for jersey [07:32]
_Tenchi_ so... even w/o the specs... you have a pretty nice stack w/ glassfish :D [07:33]
_Tenchi_ (and payara) [07:33]
_Tenchi_ of which i'm a total whore now [07:33]
whartung heh [07:34]
_Tenchi_ until payara makes me wait for more than 30 days w/o helping me with an issue, i doubt i'll be motivated to even kick the tires of wildfly [07:34]
whartung I'm on a different channel for a old style web framework and they're finally trying to make it more HTTP RPC friendly, and that means support for JSON. But that means "picking" a json lib, since there's no standard, they're not really pluggable right now, so we were looking at what JEE was doing seeing if we could leverage that. [07:35]
_Tenchi_ jersey is pluggable, actually [07:36]
_Tenchi_ you can pick and choose your provider [07:36]
_Tenchi_ but out of the box it uses moxy [07:36]
whartung yea they'll just create a simple wrapper interface and provide an implementation for Jackson or something [07:36]
pulsar [88.198.83.182] has joined #glassfish [07:45]
pdurbin "from my experience async and java ecosystem does not fit together very well" http://irclog.greptilian.com/friendlyjava/2015-08-03 [07:45]
javabot pdurbin's title: IRC log for #friendlyjava, 2015-08-03 [07:45]
pulsar evenin' gentleman [07:45]
whartung ? and pdurbin [07:45]
whartung yea async and transactions -- that can be a h00t [07:46]
whartung so this is clever. Somehow GF managed to embed looking up application property com.sun.appserv.jsp.resource.injector in every JSP, but if you grep around for that string, you don't see it in anything related to the compiler... [07:47]
_Tenchi_ grep around for it in glassfish source code ? [07:48]
whartung si [07:48]
whartung they appear to use the raw JspC from apache [07:48]
whartung which, shockingly, has no reference to it either... [07:49]
_Tenchi_ time to employ your favorite decompiler [07:49]
whartung and even that's amazing since,, in fact, there IS not "stand alone" JspC from Apache, it's only bundled with Tomcat., yet it's not in the source tree?. [07:49]
whartung scratches his chin and goes "Hmmm" [07:49]
_Tenchi_ ugh, is it a non-opensource component or somthing ? [07:50]
whartung no, it's open source, it's apache [07:50]
whartung it's just not independent [07:50]
whartung you can't maven a dependency on just JspC [07:50]
whartung there's no "JspC" project [07:50]
whartung it's buried in TC [07:50]
whartung So here's the nut [08:02]
whartung the jsp compiler [08:02]
whartung created lines like this: [08:02]
whartung org.apache.taglibs.standard.tag.rt.core.ForEachTag _jspx_th_c_forEach_0 = (_jspx_resourceInjector != null) ? _jspx_resourceInjector.createTagHandlerInstance(org.apache.taglibs.standard.tag.rt.core.ForEachTag.class) : new org.apache.taglibs.standard.tag.rt.core.ForEachTag(); [08:02]
whartung which says "if there's a jspx_resourceInjector, use that to create a tag, otherwise, just create one with new" [08:03]
whartung the resourceInjector comes from teh app context: [08:03]
whartung _jspx_resourceInjector = (org.glassfish.jsp.api.ResourceInjector) application.getAttribute("com.sun.appserv.jsp.resource.injector"); [08:03]
whartung and that is an internal, GF ResourceInjectorImpl [08:04]
whartung for good times, it appears to do this regardless of the fact that I have enablePooling set to FALSE in the jsp-config [08:04]
whartung well, this killed my leak cold - it seems: getServletContext().setAttribute("com.sun.appserv.jsp.resource.injector", null); [08:27]
whartung see what happens when I role it out to dev in the morning. [08:27]
_Tenchi_ whartung: you guys run the glassfish commercial patches? or opensource distro ? [09:06]