Re: [SOLVED] ERJGroupsSynchronization Exception
Re: [SOLVED] ERJGroupsSynchronization Exception
- Subject: Re: [SOLVED] ERJGroupsSynchronization Exception
- From: Nathan Hadfield <email@hidden>
- Date: Tue, 20 Jan 2009 15:50:42 -0700
I am getting _EOAssertSafeMultiThreaddedAccess traces when the
ERXObjectStoreCoordinatorSynchronizer kicks in. Similarly to what Saad
found in the processRmoteChange() method, they are coming from an
assertion just before locking the database context in the _process()
method:
if (snapshotsByGlobalID.count() > 0) {
EODatabaseContext._EOAssertSafeMultiThreadedAccess(dbc);
dbc.lock();
try {
processor.processSnapshots(dbc, database, snapshotsByGlobalID,
settings);
}
finally {
dbc.unlock();
}
}
Am I correct that we would NOT necessarily expect the dbc to be locked
when _EOAssetSafeMultiThreadedAccess() is invoked--and that the method
should be fixed to lock the dbc before the assertion?
Thanks in advance,
Nathan
On Oct 24, 2008, at 3:00 PM, Chuck Hill wrote:
On Oct 24, 2008, at 1:55 PM, Saad Laassel wrote:
We finally figured out what was "wrong":
There's a call to
EODatabaseContext._EOAssertSafeMultiThreadedAccess(); on line 528
of ERXObjectStoreCoordinatorSynchronizer.java that call results in
the "*** EODatabaseContext: access without lock" message being
logged.
The good news is that EODatabaseContext in question ends up being
locked right after that...
Code snippet from
ERXObjectStoreCoordinatorSynchronizer.processRemoteChange();
EODatabaseContext dbc =
ERXEOAccessUtilities.databaseContextForEntityNamed(osc,
gid.entityName());
EODatabase database = dbc.database();
EODatabaseContext._EOAssertSafeMultiThreadedAccess(dbc);
dbc.lock();
I supposed all that needs to be done here is to lock the
EODatabaseContext before calling
_EOAssertSafeMultiThreadedAccess(); How would one go about
submitting a patch?
Good catch!
See http://wiki.objectstyle.org/confluence/display/WONDER/Creating+and+Submitting+an+Acceptable+Patch
Chuck
On Oct 23, 2008, at 6:32 PM, Chuck Hill wrote:
On Oct 23, 2008, at 2:55 PM, Saad Laassel wrote:
This is a follow on to this issue, we are deploying as a servlet
using WO 5.4.3 we modified our Database Context Delegate so it
now extends ERXDatabaseContextDelegate, we are initializing the
remote synchronizer manually by calling:
ERXObjectStoreCoordinatorSynchronizer
.synchronizer().initializeRemoteSynchronizer();
this is happening very early on in our application.java right
after we receive "ModelAddedNotification", everything seems to
behave as it should e.g. cached objects are being refreshed on
different instances except we are getting the following exception
on a frequent basis:
[Thread-2] DEBUG NSLog - *** EODatabaseContext: access without
lock
Our application is usually deployed in a multi-server, multi-
instance environment we just want to make sure this is not going
to create any locking issues... any help is greatly
appreciated ...
I'd take that warning very seriously. If that is not a bogus
message, it is a serious problem.
Chuck
On Oct 22, 2008, at 10:56 AM, Dov Rosenberg wrote:
We converted over to Project Wonder to use the
EJGroupsSynchronizer – everything looks like it is working OK
except I see this exception throughout the log file
[Thread-2] DEBUG NSLog - *** EODatabaseContext: access without
lock!
I did a thread dump to see what was executing when this was
occurring – it looks like the problem is in the
ERXObjectStoreCoordinatorSynchronizer.
"Thread-2" prio=6 tid=0x62d92780 nid=0x40c in Object.wait()
[0x6339f000..0x6339fd9c]
at java.lang.Object.wait(Native Method)
- waiting on <0x0d132540> (a java.util.LinkedList)
at java.lang.Object.wait(Unknown Source)
at er.extensions.eof.ERXObjectStoreCoordinatorSynchronizer
$
ProcessChangesQueue
.run(ERXObjectStoreCoordinatorSynchronizer.java:572)
- locked <0x0d132540> (a java.util.LinkedList)
at java.lang.Thread.run(Unknown Source)
Any thoughts on this? I am a little nervous about adding lock()
statements into the Wonder code.
Thanks in advance for any feedback.
Dov Rosenberg
_______________________________________________
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
--
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