For a change, something pretty weird.
I've got a report with a log which includes
===
25.2 11:00:21: about to perform 2 DB operations in
er.extensions.eof.ERXEC@63be527e...
- 1: INSERT on 'DBUserAuction' 4{creationDate:2015-02-25 10:00:19 Etc/GMT,
user_id:1000042, auction_id:1000260, favourited:false}
- 2: UPDATE on 'DBAuction' ((uid = 1000260) and (commodityPriceSelectionType =
1040355))
1{commodityTimechunksString:<com.webobjects.foundation.NSKeyValueCoding$Null>}
cannot save changes: Cannot obtain globalId for an object which is registered
in an other than the databaseContext's active editingContext, object:
<DBAuction@820157825 PK:1000260 E:1 Title:'Dodávka elekt?iny v nap??ové hladin?
nízkého nap?tí' /EC:749e8ece>, databaseContext:
com.webobjects.eoaccess.EODatabaseContext@43afebc9, object's editingContext:
er.extensions.eof.ERXEC@749e8ece, databaseContext's active editingContext:
er.extensions.eof.ERXEC@63be527e
at cz.ocs.Static.PRINT_ERROR(Static.groovy:15)
at
cz.ocs.model.OCSEnterpriseObject.saveChangesWithEC(OCSEnterpriseObject.groovy:812)
at
cz.ocs.model.OCSEnterpriseObject.saveChangesWithEC(OCSEnterpriseObject.groovy)
at cz.ocs.model.OCSEnterpriseObject$saveChangesWithEC$7.call(Unknown
Source)
at app.Session.saveChanges(Session.groovy:210)
...
===
Now, at the surface, it makes perfect sense -- my own logs concur that EC
63be527e was saving and that the DBAuction object belonged to EC 749e8ece, EOF
has full right to scream.
I wonder though -- how the H might it happen that an object of another EC gets
into this one's update list?!? That's the main reason I write: is there a
well-known condition which would lead to this? Note that no objects were added
to any relationships; simply, one has been inserted, another updated[*].
Note: both ECs, far as I can say from the logs, seem to be defaultECs of
different sessions. The one in which the save was attempted indeed belonged to
the user who initiated the request; so far I haven't been able to find any link
to the other user, its session or its EC (it run concurrently, without any
problem).
Also: there was not one exception reported from the launch; this weirdness is
the first problem in my whole log. And those background import tasks of mine,
which might smell fishy for they use their own ECs, were not run at all.
[*] Finally, whilst the INSERT is all right and should happen precisely this
way, the UPDATE is fishy and should not happen -- actually, most time from the
moment I've got the report I've spend finding how the darn it is possible that
commodityTimechunksString gets NULLed, and so far the only result is „magic“ --
none of parts of my code which might do that had any right to be run at the
moment.
Thanks and all the best,
OC
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com
This email sent to [email protected]