Re: A WOLongResponsePage that _sometimes_ seems to create a deadlock
Re: A WOLongResponsePage that _sometimes_ seems to create a deadlock
- Subject: Re: A WOLongResponsePage that _sometimes_ seems to create a deadlock
- From: Kaj Hejer <email@hidden>
- Date: Tue, 10 May 2005 09:53:43 +0200
On 9. mai 2005, at 18.41, Chuck Hill wrote:
public void awake() {
super.awake();
if (editingContext != null && isPerformActionFinished) {
editingContext.lock(); //line 103
What else uses this editing context? Either it has it locked or,
as Anjo pointed out, awake got called twice and sleep once in a
previous request and the EC was left locked.
Hi!
Thanks again for answering!
What we have is a WOLongResponsePage that have its own
ObjectStoreCoordinator and ec. When looking at the component for the
10th time I see that we don't actually use the ec we create in the
component at all! We only use it in performAction. So the locking
stuff in awake/sleep wasn't needed.
*blush*
Well.... gone is now the unlock/lock in awake/sleep :) and the
declaration and creation of the ec is moved to performAction and
propper locking is implemented! :)
We add a patch yesterday to the deployed version of this application
(this is before I removed the lockingstuff from awake/sleep) that use
LockErrorScreamerEditingContext instad of EOEditingContext in this
component so we might get some more info about what was wrong, and we
did! :) and you were right! It was the locking in awake that was the
source of the problem (line 104 is the line that locks the ec):
log: 2005.05.09 16:17:24:123 CEST:Rapport1.awake: before lock
[2005-05-09 16:17:24 MEST] <WorkerThread10> !!! Attempting to lock
editing context from WorkerThread10 that was previously locked in
WorkerThread5
[2005-05-09 16:17:24 MEST] <WorkerThread10> !!! Current stack trace:
java.lang.Throwable
at LockErrorScreamerEditingContext._trace
(LockErrorScreamerEditingContext.java:95)
at LockErrorScreamerEditingContext.lock
(LockErrorScreamerEditingContext.java:52)
at Rapport1.awake(Rapport1.java:104)
at com.webobjects.appserver.WOComponent._awakeInContext
(WOComponent.java:862)
at com.webobjects.appserver.WOSession.restorePageForContextID
(WOSession.java:710)
Thanks again for helping us with this issue!
-Kaj :)
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden