Hi Maik, I also have some strange behaviour with background thread... I remember something about child thread (and process) that inherits environment variable form their parent. I think we experience something like this.
In the ERXThreadStorage class there is reference to a property er.extensions.ERXThreadStorage.useInheritableThreadLocal set to true by default. My understanding of the feature is a child thread will get the current value of the thread that created it when accessing the map. I suggest trying to set this property to false, maybe this is the problem. Samuel > Le 1 avr. 2016 à 10:59, Maik Musall <[email protected]> a écrit : > > Hi Samuel, > > the callstack is actually longer, and from that and the context around it I > already know that this happens both when rendering a component in background > threads as well as in traditional WORequest frontend processing in user > sessions. But the phenomenon is new and started at around the time I began > using ERXElse in background threads. > > As only a handful small components are used in those background threads, this > was easily fixed by changing the tags to standard webobject tags with > condition bindings instead of using wo:if and wo:else. > > Maik > > >> Am 31.03.2016 um 14:39 schrieb Samuel Pelletier <[email protected]>: >> >> Maik, >> >> It is not really a global static dictionary, it is stored in thread storage >> so no concurrency problem... >> >> This does not help you much though. >> >> I would try to catch the exception to add log context information like the >> current request of page being rendered. >> >> Samuel >> >>> Le 30 mars 2016 à 07:56, Maik Musall <[email protected]> a écrit : >>> >>> Hi all, >>> >>> I’ve been getting these a lot lately: >>> >>> java.lang.IllegalStateException: You attempted to use an ERXElse without a >>> preceding conditional. >>> at >>> er.extensions.components.conditionals.ERXElse.lastConditionChecked(ERXElse.java:29) >>> at >>> er.extensions.components.conditionals.ERXElse.appendToResponse(ERXElse.java:54) >>> at >>> com.webobjects.appserver._private.WODynamicGroup.appendChildrenToResponse(WODynamicGroup.java:126) >>> at >>> com.webobjects.appserver._private.WODynamicGroup.appendToResponse(WODynamicGroup.java:136) >>> at >>> com.webobjects.appserver.WOComponent.appendToResponse(WOComponent.java:1122) >>> >>> Of course the wo:if-wo:else tags are correct. Turns out ERXElse holds the >>> lastCondition state in a static (!) dictionary. How is this even supposed >>> to work with high concurrency? >>> >>> In my case, I’m rendering HTML in background threads to be delivered on the >>> next Ajax poll, which seems to interfere with foreground worker threads. >>> >>> Any thoughts on this? >>> >>> Thanks >>> Maik >>> >>> _______________________________________________ >>> Do not post admin requests to the list. They will be ignored. >>> Webobjects-dev mailing list ([email protected]) >>> Help/Unsubscribe/Update your Subscription: >>> https://lists.apple.com/mailman/options/webobjects-dev/samuel%40samkar.com >>> >>> This email sent to [email protected] > > _______________________________________________ > Do not post admin requests to the list. They will be ignored. > Webobjects-dev mailing list ([email protected]) > Help/Unsubscribe/Update your Subscription: > https://lists.apple.com/mailman/options/webobjects-dev/samuel%40samkar.com > > This email sent to [email protected] _______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list ([email protected]) Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [email protected]
