• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Where is the deadlock culprit?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Where is the deadlock culprit?


  • Subject: Re: Where is the deadlock culprit?
  • From: Kieran Kelleher <email@hidden>
  • Date: Wed, 3 Dec 2008 15:59:53 -0500

BTW, ERXSession.sleep() does not have this .... should it have this technique too?

On Dec 3, 2008, at 3:48 PM, Chuck Hill wrote:

Nooooooo. I am thinking of something else. Sorry, my bad. sleep() MUST... NOT... THROW...

What Ken said was correct:

public void sleep() {
 try {
	// your code here
 } (Exception e) {
	logger.error("Exception thrown in sleep code", e);
 } finally {
	super.sleep();
 }
}

Chuck





On Dec 3, 2008, at 12:38 PM, Chuck Hill wrote:


On Dec 3, 2008, at 12:33 PM, Kieran Kelleher wrote:

OK. thanks. I have implemented that in sleep and my Session subclasses. .... except I added a catch and log.error aswell so we will get an email if I get an error in sleep() So we will see ........ it might be a year before I see this error again .....

if you have no catch statement as shown in your example won't this throw anyway?

It will throw, but the important part is that super.sleep() will be called whether it throws or not.


Chuck




Kieran

On Dec 3, 2008, at 3:17 PM, Chuck Hill wrote:


On Dec 3, 2008, at 12:15 PM, Kieran Kelleher wrote:

You mean wrap contents of sleep and terminate with try/catch and don't throw, just log it?

That is what I started doing long ago. I think this is a better solution:


public void sleep() {
try {
	// your code here
} finally {
	super.sleep();
}
}


Chuck





On Dec 3, 2008, at 2:55 PM, Chuck Hill wrote:

I can confidently claim to be completely unsure. ;-) If the MultiECLockManager still had it locked, it may not be able to. I don't use ERXEC so I really don't know. Check your Sessions() sleep() and terminate() methods (and any super class you have) to ensure that they can't throw an exception.



-- Chuck Hill Senior Consultant / VP Development

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects










-- Chuck Hill Senior Consultant / VP Development

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects








-- Chuck Hill Senior Consultant / VP Development

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects







_______________________________________________ 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

_______________________________________________ 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
  • Follow-Ups:
    • Re: Where is the deadlock culprit?
      • From: Chuck Hill <email@hidden>
References: 
 >Where is the deadlock culprit? (From: Kieran Kelleher <email@hidden>)
 >Re: Where is the deadlock culprit? (From: Anjo Krank <email@hidden>)
 >Re: Where is the deadlock culprit? (From: Chuck Hill <email@hidden>)
 >Re: Where is the deadlock culprit? (From: Kieran Kelleher <email@hidden>)
 >Re: Where is the deadlock culprit? (From: Chuck Hill <email@hidden>)
 >Re: Where is the deadlock culprit? (From: Kieran Kelleher <email@hidden>)
 >Re: Where is the deadlock culprit? (From: Chuck Hill <email@hidden>)
 >Re: Where is the deadlock culprit? (From: Kieran Kelleher <email@hidden>)
 >Re: Where is the deadlock culprit? (From: Chuck Hill <email@hidden>)
 >Re: Where is the deadlock culprit? (From: Chuck Hill <email@hidden>)

  • Prev by Date: Re: Where is the deadlock culprit?
  • Next by Date: Re: Where is the deadlock culprit?
  • Previous by thread: Re: Where is the deadlock culprit?
  • Next by thread: Re: Where is the deadlock culprit?
  • Index(es):
    • Date
    • Thread