• 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: awake() called twice on page refresh
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: awake() called twice on page refresh


  • Subject: Re: awake() called twice on page refresh
  • From: Chuck Hill <email@hidden>
  • Date: Thu, 30 Oct 2008 13:41:49 -0700


On Oct 30, 2008, at 2:38 AM, Juergen Lorenz Simon wrote:

Hi,

we're observing some behaviour we can't seem to explain. We had a problem with
application deadlocking. It turned out that the lock was ERDPage (a ProjectWonder
component) which locks an editing context in awake() and unlocks it again in sleep().

That sounds odd to find this in Wonder. This is a known unsafe way to lock editing contexts. IIRC, this was one of the reasons that the ERXEC technology was created - safe locking with D2W. Is this some old component that never got updated?




However, the component itself is not to blame. The problem only occurs, when the
user uses the reload button. In that case, some component's awake() method is actually
called twice! We have no explanation for this.


The calls to awake() and sleep() are not guaranteed to be balanced. Those methods should not be used for purposes like this until you also include a semaphore. Even then, I would avoid it.

Chuck

--
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
  • Follow-Ups:
    • Re: awake() called twice on page refresh
      • From: Guido Neitzer <email@hidden>
    • Re: awake() called twice on page refresh
      • From: Ramsey Gurley <email@hidden>
References: 
 >awake() called twice on page refresh (From: Juergen Lorenz Simon <email@hidden>)

  • Prev by Date: NSSelector and Void Returned Value
  • Next by Date: Re: EOF and the Observer Pattern
  • Previous by thread: awake() called twice on page refresh
  • Next by thread: Re: awake() called twice on page refresh
  • Index(es):
    • Date
    • Thread