• 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: Some help with Optimization
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Some help with Optimization


  • Subject: Re: Some help with Optimization
  • From: Art Isbell <email@hidden>
  • Date: Thu, 9 Feb 2006 17:47:34 -1000

On Feb 9, 2006, at 4:32 PM, Chuck Hill wrote:

On Feb 9, 2006, at 4:11 PM, Art Isbell wrote:

EOModelGroup defaultGroup = EOModelGroup.defaultGroup();
EODatabaseContext databaseContext = EODatabaseContext.registeredDatabaseContextForModel (defaultGroup.modelNamed("ModelName"), ec);


=8-0 SHRIEK!

Indeed!

databaseContext.lock();
try {
databaseContext.batchFetchRelationship(defaultGroup.entityNamed ("External").relationshipNamed("activeName"), tempAllExs, ec);
selectableExtenals = (NSArray)tempAllExs.valueForKey("activeName");


}
finally {
    databaseContext.unlock();
}

Yes, you need to. Really.

It's been so long since I accessed an EODatabaseContext directly that I forgot about locking. Instead, I invoke my own batchFetchRelationship() defined in the superclass of my Model classes which is in a framework linked by various WO apps. My implementation locks the database context before invoking EODatabaseContext's batchFetchRelationship(). I apologize for misleading anyone.


Aloha,
Art

_______________________________________________
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


References: 
 >Some help with Optimization (From: Owen McKerrow <email@hidden>)
 >Re: Some help with Optimization (From: Art Isbell <email@hidden>)
 >Re: Some help with Optimization (From: Chuck Hill <email@hidden>)

  • Prev by Date: tomcat deployment
  • Next by Date: Re: WO, Java and Microsoft Active Directory
  • Previous by thread: Re: Some help with Optimization
  • Next by thread: Re: Some help with Optimization
  • Index(es):
    • Date
    • Thread