Preventing Scheduled Process Models from kicking off multiple instances after system downtime?

Certified Senior Developer
Does anyone have any recommended approaches to preventing a process model that runs on a recurring schedule from kicking off multiple instances after the system is down when it was scheduled to run? We have some processes that run nightly, but can create race-conditions if multiple instances try to run simultaneously.

Thinking about maybe putting in an "Advanced Options" Expression to force it to actually be the scheduled start time (or at least close), and just bypassing running until the next scheduled time that Appian is actually up on the server. Would that do the trick?

OriginalPostID-254265

  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Lead Developer
    It seems to me like your 'advanced options' idea might be the best shot for now - i.e. install a gateway shortly after the start node to determine whether the current time is the same as the scheduled starting time (or maybe within a certain margin), and otherwise just exit.

    Also if the DB lock thing is still something you'd consider, I was able to devise a SQL 'trick' that will read a DB value while simultaneously incrementing it, tightly enough that 2 processes executing simultaneously wouldn't get a race condition. The same might work in your case.
Reply
  • 0
    Certified Lead Developer
    It seems to me like your 'advanced options' idea might be the best shot for now - i.e. install a gateway shortly after the start node to determine whether the current time is the same as the scheduled starting time (or maybe within a certain margin), and otherwise just exit.

    Also if the DB lock thing is still something you'd consider, I was able to devise a SQL 'trick' that will read a DB value while simultaneously incrementing it, tightly enough that 2 processes executing simultaneously wouldn't get a race condition. The same might work in your case.
Children
No Data