Globals Conflict on FMSglobals fms multi-thread
Posted 16 February 2012 - 09:35 AM
1. If Schedule 1 takes 3 hrs and Schedule 2 starts at 2am, does it run concurrently or wait until Schedule1 is complete?
2. If it runs concurrently, does Schedule 2 run the File's Open Script or does it say, "hmm...I already have a session, I'll skip the Open Script?"
I ask because we are seeing unexpected settings to our global fields. These fields are set in the Open Script. We're starting to think concurrent server scripts are "overwriting" the global values. We are considering a master server script controller to avoid concurrent server scripts (if that's necessary).
Posted 16 February 2012 - 10:18 AM
Posted 16 February 2012 - 10:29 AM
Posted 16 February 2012 - 11:17 AM
Let me clarify. These scripts set fields in records to the global value. We are receiving the incorrect global value.
It seems to me the only Global values that the server can draw from were either there when the file was hosted or they would have to have been set by the server previously.
Barbara, I know you are far more advanced than I, so I'm just curious more so than trying to offer an answer. I doubt I could come up with anything you haven't already thought of.
Posted 16 February 2012 - 11:37 AM
- Create a script that pauses for a few min (if pause isn't a server compatible step, then have it do something to take up a few min. time).
- Make the "on file open" script create a new record, and insert the current timestamp into a field.
- Schedule the server to run the "pause" script twice: 1 min apart (separate schedules)
- Look at the records created, and the time's in the timestamp field.
- If only one record is created, then the "on file open" script IS skipped for the second script
- If two records are created, and the time between the timestamps is more than 1 min. apart, then the server does wait for the first script
- If two records are created, and the time between the timestamps is 1 min, then they are both triggered on schedule, regardless of other running scripts
Posted 17 February 2012 - 08:56 AM
Thank you for the suggestions.