Re: Tracking EC Locking Issues when using MultiECLockManager and LockErrorScreamerEditingContext

2008-05-21 Thread Chuck Hill
t" + sessionID()); numAccessInLastMinute = 1; timeSinceLastCalled = new NSTimestamp(); ecLockManager = new MultiECLockManager(); setDefaultEditingContext(new LockErrorScreamerEditingContext()); } I don't understand why the _sleepInConte

Re: Tracking EC Locking Issues when using MultiECLockManager and LockErrorScreamerEditingContext

2008-05-20 Thread Anjo Krank
You can NOT lock/unlock ECs reliably in awake/sleep without some safeguarding like ERXEC or the MECLM. D2W, which uses this method exclusively, is totally unusable without it. All it takes is one submit and a reload to lock up your session or app. Cheers, Anjo Am 21.05.2008 um 02:34 schrie

Re: Tracking EC Locking Issues when using MultiECLockManager and LockErrorScreamerEditingContext

2008-05-20 Thread Owen McKerrow
ic Session() throws Exception { super(); log.info("\tSession has been created.\t" + sessionID()); numAccessInLastMinute = 1; timeSinceLastCalled = new NSTimestamp(); ecLockManager = ne

Re: Tracking EC Locking Issues when using MultiECLockManager and LockErrorScreamerEditingContext

2008-05-20 Thread Michelle Parker
track down my locking issues I implemented the LockErrorScreamerEditingContext but unfortunately its not going to be as useful as I had hoped. I changed my MultiECLockManager to use a LockErrorScreamerEditingContext but of course this means that every lock will come from it, so when I get

Re: Tracking EC Locking Issues when using MultiECLockManager and LockErrorScreamerEditingContext

2008-05-20 Thread Chuck Hill
On May 18, 2008, at 8:41 PM, Owen McKerrow wrote: Hi All, In an effort to track down my locking issues I implemented the LockErrorScreamerEditingContext but unfortunately its not going to be as useful as I had hoped. I changed my MultiECLockManager to use a

Re: Tracking EC Locking Issues when using MultiECLockManager and LockErrorScreamerEditingContext

2008-05-20 Thread Lachlan Deck
MultiECLockManager to use a LockErrorScreamerEditingContext but of course this means that every lock will come from it, so when I get errors like the one below, the original stack trace that it prints out will always be from WOSession._awakeInContext. So does anyone have any other suggestions as to

Re: Tracking EC Locking Issues when using MultiECLockManager and LockErrorScreamerEditingContext

2008-05-19 Thread Lachlan Deck
On 20/05/2008, at 9:29 AM, Owen McKerrow wrote: In an effort to track down my locking issues I implemented the LockErrorScreamerEditingContext but unfortunately its not going to be as useful as I had hoped. I changed my MultiECLockManager to use a LockErrorScreamerEditingContext but of

Re: Tracking EC Locking Issues when using MultiECLockManager and LockErrorScreamerEditingContext

2008-05-19 Thread Owen McKerrow
In an effort to track down my locking issues I implemented the LockErrorScreamerEditingContext but unfortunately its not going to be as useful as I had hoped. I changed my MultiECLockManager to use a LockErrorScreamerEditingContext but of course this means that every lock will come from

Re: Tracking EC Locking Issues when using MultiECLockManager and LockErrorScreamerEditingContext

2008-05-19 Thread Lachlan Deck
Hi Owen, On 19/05/2008, at 1:41 PM, Owen McKerrow wrote: In an effort to track down my locking issues I implemented the LockErrorScreamerEditingContext but unfortunately its not going to be as useful as I had hoped. I changed my MultiECLockManager to use a LockErrorScreamerEditingContext

Tracking EC Locking Issues when using MultiECLockManager and LockErrorScreamerEditingContext

2008-05-18 Thread Owen McKerrow
Hi All, In an effort to track down my locking issues I implemented the LockErrorScreamerEditingContext but unfortunately its not going to be as useful as I had hoped. I changed my MultiECLockManager to use a LockErrorScreamerEditingContext but of course this means that every lock will

Re: Unable to release locks when using MultiECLockManager

2008-04-30 Thread Chuck Hill
On Apr 30, 2008, at 8:45 PM, Owen McKerrow wrote: On 01/05/2008, at 1:27 PM, Chuck Hill wrote: Im willing to "donate" this problem to your "Best pratices" session at WOWODC Chuck, so that you can give us a real life example ; ) :-) Chuck So I take it from that smile then that you

Re: Unable to release locks when using MultiECLockManager

2008-04-30 Thread Owen McKerrow
On 01/05/2008, at 1:27 PM, Chuck Hill wrote: Im willing to "donate" this problem to your "Best pratices" session at WOWODC Chuck, so that you can give us a real life example ; ) :-) Chuck So I take it from that smile then that you would be happy to. Great I'll start taring up the p

Re: Unable to release locks when using MultiECLockManager

2008-04-30 Thread Chuck Hill
On Apr 29, 2008, at 10:48 PM, Owen McKerrow wrote: On 30/04/2008, at 3:09 PM, Chuck Hill wrote: On Apr 29, 2008, at 8:08 PM, Art Isbell wrote: On Apr 29, 2008, at 4:47 PM, Owen McKerrow wrote: I remember discussing MultiECLockManager on list last year with chuck Hill ( http

Re: Unable to release locks when using MultiECLockManager

2008-04-30 Thread Chuck Hill
On Apr 30, 2008, at 4:24 PM, Owen McKerrow wrote: Hi Again, Please see below Owen McKerrow WebMaster, emlab Ph : +61 02 4221 5517 http://emlab.uow.edu.au - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 'The test of a first-rate intelligence is t

Re: Unable to release locks when using MultiECLockManager

2008-04-30 Thread Lachlan Deck
You need to throw an instanceof RuntimeException. On 01/05/2008, at 9:24 AM, Owen McKerrow wrote: Now this may be a basic Java question and I tried to ask it yesterday, but probably in a very poor fashion. When your dealing with overriding a method and the original method does not throw an

Re: Unable to release locks when using MultiECLockManager

2008-04-30 Thread Owen McKerrow
Hi Again, Please see below Owen McKerrow WebMaster, emlab Ph : +61 02 4221 5517 http://emlab.uow.edu.au - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 'The test of a first-rate intelligence is the ability to hold two opposed ideas in the mind a

Re: Unable to release locks when using MultiECLockManager

2008-04-29 Thread Owen McKerrow
On 30/04/2008, at 3:09 PM, Chuck Hill wrote: On Apr 29, 2008, at 8:08 PM, Art Isbell wrote: On Apr 29, 2008, at 4:47 PM, Owen McKerrow wrote: I remember discussing MultiECLockManager on list last year with chuck Hill ( http://lists.apple.com/archives/Webobjects-dev/2007/ Apr/msg00609

Re: Unable to release locks when using MultiECLockManager

2008-04-29 Thread Chuck Hill
On Apr 29, 2008, at 8:08 PM, Art Isbell wrote: On Apr 29, 2008, at 4:47 PM, Owen McKerrow wrote: I remember discussing MultiECLockManager on list last year with chuck Hill ( http://lists.apple.com/archives/Webobjects-dev/2007/Apr/msg00609.html ) who pointed out that he'd tw

Re: Unable to release locks when using MultiECLockManager

2008-04-29 Thread Chuck Hill
Art Isbell wrote: On Apr 29, 2008, at 2:24 PM, Owen McKerrow wrote: Sorry all, I should have specified that further. Has anyone seen it whilst using MultiECLockManager ? No, but you must use MultiECLockManager correctly. Are you invoking MultiECLockManager.unlock() in Session.sleep()

Re: Unable to release locks when using MultiECLockManager

2008-04-29 Thread Owen McKerrow
app that creates its own EOEditingContext which is not registered with the MultiECLockManager, but it a ec.unlock() in the finallly() section of its try catch block. finally{ if ( ec != null ) { ec.unlock(); ec.dispose(); } } I check

Re: Unable to release locks when using MultiECLockManager

2008-04-29 Thread Art Isbell
On Apr 29, 2008, at 4:47 PM, Owen McKerrow wrote: I remember discussing MultiECLockManager on list last year with chuck Hill ( http://lists.apple.com/archives/Webobjects-dev/2007/Apr/msg00609.html ) who pointed out that he'd tweaked MultiECLockManager inside his GVCWOExtensions fram

Re: Unable to release locks when using MultiECLockManager

2008-04-29 Thread Owen McKerrow
()) { ecLockManager().unlock(); } } super.sleep(); } Hmm, the version of MultiECLockManager that I use doesn't implement isLocked(), so I don't know what isLocked() accomplishes. The only public methods are lock

Re: Unable to release locks when using MultiECLockManager

2008-04-29 Thread Art Isbell
(); } } super.sleep(); } Hmm, the version of MultiECLockManager that I use doesn't implement isLocked(), so I don't know what isLocked() accomplishes. The only public methods are lock(), unlock(), registerEditingCont

Re: Unable to release locks when using MultiECLockManager

2008-04-29 Thread Owen McKerrow
On Apr 29, 2008, at 2:24 PM, Owen McKerrow wrote: Sorry all, I should have specified that further. Has anyone seen it whilst using MultiECLockManager ? No, but you must use MultiECLockManager correctly. Are you invoking MultiECLockManager.unlock() in Session.sleep() before any statement

Re: Unable to release locks when using MultiECLockManager

2008-04-29 Thread Art Isbell
On Apr 29, 2008, at 2:24 PM, Owen McKerrow wrote: Sorry all, I should have specified that further. Has anyone seen it whilst using MultiECLockManager ? No, but you must use MultiECLockManager correctly. Are you invoking MultiECLockManager.unlock() in Session.sleep() before any statement

Re: Unable to release locks when using MultiECLockManager

2008-04-29 Thread Owen McKerrow
Sorry all, I should have specified that further. Has anyone seen it whilst using MultiECLockManager ? Owen McKerrow WebMaster, emlab Ph : +61 02 4221 5517 http://emlab.uow.edu.au - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - "I like the way

Re: Unable to release locks when using MultiECLockManager

2008-04-29 Thread Chuck Hill
java.lang.ref.Finalizer.runFinalizer(Finalizer.java:83) at java.lang.ref.Finalizer.access$100(Finalizer.java:14) at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:160) Im using MultiECLockManager to handle all the locking and unlocking, so Im wondering if anyone else has seen this kind of error and what I can

Unable to release locks when using MultiECLockManager

2008-04-29 Thread Owen McKerrow
$100(Finalizer.java:14) at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:160) Im using MultiECLockManager to handle all the locking and unlocking, so Im wondering if anyone else has seen this kind of error and what I can do to chase it up. Owen McKerrow WebMaster, emlab Ph : +61

Re: Illegal State Exceptions when using MultiECLockManager

2008-02-27 Thread Chuck Hill
the MultiECLockManager() to manage its EditingContexts EXCEPTION: java.lang.IllegalStateException: prepareForSaveWithCoordinator: [EMAIL PROTECTED] is currently saving for [EMAIL PROTECTED] so it cannot prepare to save for [EMAIL PROTECTED] [EMAIL PROTECTED] has sources ([EMAIL

Illegal State Exceptions when using MultiECLockManager

2008-02-27 Thread Owen McKerrow
Hi All, Over the past couple of days I have received some emails from one of my apps which is using the MultiECLockManager() to manage its EditingContexts EXCEPTION: java.lang.IllegalStateException: prepareForSaveWithCoordinator: [EMAIL PROTECTED] is currently saving for [EMAIL

Re: MultiECLockManager. Set and forget ?

2007-04-25 Thread Kieran Kelleher
Many ways to skin the cat here Your own EC subclass, MultiECLockManager and Wonder are all not mutually exclusive. I've been using them in combination since I first adopted WOnder because I was using MultiECLockManager before that. The only thing you need to do for Wonder integr

Re: MultiECLockManager. Set and forget ?

2007-04-25 Thread Chuck Hill
Hi Owen, On Apr 25, 2007, at 5:12 PM, Owen McKerrow wrote: Im looking at cleaning up our locking procedures on some of our projects. Looking over past emails and on the wiki the most commons suggestions are either MultiECLockManager or Project Wonders ERXEC. We're not using Wond

Re: MultiECLockManager. Set and forget ?

2007-04-25 Thread Miguel Arroz
Hi! Yes, basically, it works automatically. You don't even have to worry about de-regestering the contexts, they will be automatically put away by the memory manager (MultiECLockManager uses soft- references). Remember that you cannot call dispose() method on registered con

MultiECLockManager. Set and forget ?

2007-04-25 Thread Owen McKerrow
Hi All, Im looking at cleaning up our locking procedures on some of our projects. Looking over past emails and on the wiki the most commons suggestions are either MultiECLockManager or Project Wonders ERXEC. We're not using Wonder at the moment so Im thinking MultiECLockManager. I

Re: MultiECLockManager

2005-11-21 Thread Jean-François Veillette
Le 05-11-20, à 03:52, David Teran a écrit : The advantage of a factory method for creating all your own subclass EC's is that you can modify in one place how EC's are created and create EC's that are of special use to you. My WKEditingContext subclass is preloaded with a .user() method that re

Re: MultiECLockManager

2005-11-20 Thread Kieran Kelleher
I agree there is no need. It does not break anything to just start using ERXEC if you have already integrated MultiECLockManager. The EC's just get unlocked before the ERXEC automatic check-and-unlock at the end of the R-R, so they don't get unlocked because they already are unlock

Re: MultiECLockManager

2005-11-20 Thread David Teran
Am 20.11.2005 um 14:37 schrieb Kieran Kelleher: However if I use the er.extensions.ERXApplication.useEditingContextUnlocker=true and ditched MultiECLockManager, would I not have to then add a mechanism for locking at session awake?? I recall a thread message from Anjo Krank at one time

Re: MultiECLockManager

2005-11-20 Thread Kieran Kelleher
nder. Basically I use this factory method to create all my EC's. If I want a regular EC whose locking is managed by the MultiECLockManager, I simply call the factory method passing the current WOContext as a param. The factory method detects that an object of type WOContext was passed and

Re: MultiECLockManager

2005-11-20 Thread David Teran
interface from erxec, start by checking ERXEC.newEditingContext(). this leads to a factory interface which you should use.Basically I use this factory method to create all my EC's.If I want a regular EC whose locking is managed by the MultiECLockManager, I simply call the factory method passing t

Re: MultiECLockManager

2005-11-19 Thread Kieran Kelleher
. If I want a regular EC whose locking is managed by the MultiECLockManager, I simply call the factory method passing the current WOContext as a param. The factory method detects that an object of type WOContext was passed and it gets the session from this and configures the new EC to work wi

Re: MultiECLockManager

2005-11-18 Thread Marcos Trejo Munguia
Hi Chuck. I was wondering if I have to use the MultiECLockManager in all my application or I can be selective?, I don't know if being selective can cause me problems (more deadlocks). You don't *have* to do anything :-) MECLM is an implementation of a generic pattern for managing

Re: MultiECLockManager

2005-11-18 Thread David LeBer
On 18-Nov-05, at 2:18 PM, Marcos Trejo Munguia wrote: Hi Chuck. I was wondering if I have to use the MultiECLockManager in all my application or I can be selective?, I don't know if being selective can cause me problems (more deadlocks). You don't *have* to do anything :-) M

MultiECLockManager

2005-11-18 Thread Marcos Trejo Munguia
Hi Chuck. I was wondering if I have to use the MultiECLockManager in all my application or I can be selective?, I don't know if being selective can cause me problems (more deadlocks). Thank you for your help. ___ Do not post admin requests t