invalidateObjectsWithGlobalIDs Problem.
invalidateObjectsWithGlobalIDs Problem.
- Subject: invalidateObjectsWithGlobalIDs Problem.
- From: Dov Rosenberg <email@hidden>
- Date: Thu, 11 Jan 2007 15:19:41 -0500
- Thread-topic: invalidateObjectsWithGlobalIDs Problem.
Title: invalidateObjectsWithGlobalIDs Problem.
A little background. We are using a JMS change notification system that invalidates objects that have been modified in other instances. At first, everything seemed to be working great, but now we realized that there are some problems fetching objects using the recently invalidated objects as part of an EOFetchEspecification qualifiers(EOQualifier).
I know that using invalidateObjectsWithGlobalIDs() at the EOObjectStoreCoordinator level will invalidate objects in all child EditingContexts – turning them into faults, but my problem is that sometimes when an invalidated object is used in a qualifier for an EOFetchEspecification, the object is not refetched and is taken as a null object in the resulting query.
For instance, suppose there is an object MyObject1 that is modified in the same instance. The change notification mechanism will send a JMS message that will be received by all instances including the one where the object was modified.
Then each instance will execute
EOObjectStoreCoordinator coordinator = EOObjectStoreCoordinator.defaultCoordinator();
coordinator.lock();
coordinator.invalidateObjectsWithGlobalIDs(globalIDS);
coordinator.unlock();
After that, a resulting List page will be returned that uses MyObject1 as part of a qualifier.
We notice that MyObject1 is not null but it is faulted when included in the qualifier, and the resulting SQL is including it as null. ( select ....... where MyObject1 is null). The problem seems to only occur for INSERTS (UPDATES and DELETES seem to be OK) and it only affects the current session. If the page is refreshed everything is fine – the EOs seem to be properly reconstituted after the refresh (i.e. They are not faulted anymore)
If anyone has any thoughts I would appreciate them. Thanks in advance
--
Dov Rosenberg
Conviveon/Inquira
Knowledge Management Experts
http://www.conviveon.com
http://www.inquira.com
_______________________________________________
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