05-04-05 07:55 AM
> I'm running into a problem where scheduled commands that update data are c
onflicting with user-initiated commands that are also trying to use that dat
a. For instance, if a user is updating his order, but a scheduled command th
at manipulates order data h
as kicked off and is in the middle of its transaction, the user's command fa
ils because it is locked out of the data by the scheduled command. To make m
atters worse, I have a clustered environment, so obvious solutions like usin
g a singleton to keep track
of which orders are in the middle of an operation will not work. Any ideas?
This seems a bit of bad luck on the timing side for the user. Can't you
reschedule the scheduler command to run in the middle of the night?
My only valid suggestion would be to modify the command to peek into the
USERS table and grab the LASTSESSION value. This would give you an idea
whether the user was logged in within the last xxx minutes and provide
assurance that the user was not online when the scheduled command was
ready to update that user's data. The command would attempt to update
those users on the next scheduled run.
R
[ Post a follow-up to this message ]
|