• 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
[WORKED AROUND] Re: Bug in client side EOF locking?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[WORKED AROUND] Re: Bug in client side EOF locking?


  • Subject: [WORKED AROUND] Re: Bug in client side EOF locking?
  • From: Stamenkovic Florijan <email@hidden>
  • Date: Wed, 28 Jan 2009 15:17:02 -0400

As you suggested, adding this to my EO superclass seems to do it:

	private static final Integer monitor = new Integer(345345);

	public void willRead(){
		synchronized(monitor){
			super.willRead();
		}
	}

	public Object willReadRelationship(Object object){
		synchronized(monitor){
			return super.willReadRelationship(object);
		}
	}

Just hope it does not introduce deadlocks in the future... Adding arbitrary synchronization is dangerous business...

Still, I'll report this. I don't believe that exception should be happening, even with the stuff I am doing...

Thanks,
F

On Jan 28, 2009, at 14:49, Stamenkovic Florijan wrote:

Accessing any EO can trigger EOF access and if you are locking around EC methods, it won't be locked at that time. You would at least need to synchronize around willRead() and willReadRelationship(). Note that willReadRelationship() locks the object store, not the EC.

Yep, noticed that. Considered making a completely synchronized EO superclass, but that seems a bit excessive; would probably wreck performance. However, synchronizing those two methods might be the way to go....

_______________________________________________ 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: [WORKED AROUND] Re: Bug in client side EOF locking?
      • From: Lachlan Deck <email@hidden>
References: 
 >Bug in client side EOF locking? (From: Stamenkovic Florijan <email@hidden>)
 >Re: Bug in client side EOF locking? (From: Chuck Hill <email@hidden>)
 >Re: Bug in client side EOF locking? (From: Stamenkovic Florijan <email@hidden>)
 >Re: Bug in client side EOF locking? (From: Chuck Hill <email@hidden>)
 >Re: Bug in client side EOF locking? (From: Stamenkovic Florijan <email@hidden>)

  • Prev by Date: Re: JadClipse and Eclipse 3.4
  • Next by Date: Re: java 1.5 enum types and EOs
  • Previous by thread: Re: Bug in client side EOF locking?
  • Next by thread: Re: [WORKED AROUND] Re: Bug in client side EOF locking?
  • Index(es):
    • Date
    • Thread