cancel
Showing results for 
Search instead for 
Did you mean: 

Unity Scripts with Library Include - Impact of updating Library on Timers/Workflow tasks

William_Howell
Star Contributor
Star Contributor

We have a Unity Library Script that is included (referenced) by most of our Unity scripts. These scripts are constantly being accessed by core based timers running as services (Hyland Workflow Timer Service), as well as by thin client users executing Ad-Hoc tasks.

When we update the Library Script, it automatically updates the links in all Unity scripts that reference the Library so as to point to the newest published version. I understand that updating an existing script doesn't require an App Pool recycle. We are running OB12.0.2.

  1. At the moment in time that a script is being updated by Config to reference the modified Unity Library, and at the same moment a timer or Ad-Hoc task tries to execute that script, is there a possibility that the script would fail?
  2. Are the scripts (including the references to the Library script) cached by the stand-alone core based timers or by the users workstations so that restarting the timer or performing a Reset Cache is required, or will these changes be picked up immediately?
Thanks!
2 REPLIES 2

Timothy_Cosgrif
Star Collaborator
Star Collaborator

Updating a script reference consists of two actions: publishing and activating.

First, the script is published. This recompiles it with the new reference and stores it in the database. If the timer is executed during this process, it will use the old version. 

Second, the script is marked as active. This is where a problem might occur. If the script is being read out of the database at the precise time of this action, there is no way of knowing exactly which script will be executing. In OnBase 13, this problem is mitigated by performing the necessary locking in the publish and activate logic.

As for your question about caching, no Unity Scripts are not cached by any of our clients. They are retrieved every time they are executed. So when you activate a script, the change will be picked up immediately.

Sriram_Seshadri
Champ in-the-making
Champ in-the-making

The workflow timer service is not connecting to the app server. So a workflow timer service does need to be restarted for it to pick up a change in script or library.