Web Service call only when field changes...

I have an expensive web service operation that I would only like to call when a field changes.
This is currently invoked during an Orchestration with Reply (Post-Transition)
The Orchestration has access to the new field value, but cannot determine if the field value has been changed.
I only want to call my web service operation if the field value has changed,
This would seem like a typical use case to me, so I would have thought there must be a simple way to do this??

The only thing I can think of is to create a new field something like InvokeWebServiceMethod.
The JavaScript could set this field to FALSE on form load.
I could then set this in JavaScript to TRUE if the field has changed.
I could then query this field in my Orchestration and only call my web service method if the value is TRUE.

It just seems that this is overly complicated and must be a better way of doing this?
I don't like the idea of creating a new field when I don't need to persist any data in the database,
We are currently using SBM 10.1.4.1 and things may be different in later versions?
I thought I remember reading something about SBM variables... but perhaps this was just a dream!! :-)

Any suggestions would be appreciated... thanks very much in advance!
Parents
  • I think the idea of using a field is sound. One thing you might look at is in your App Workflow use a decision step that will test your field value and then have it run the orchestration or just skip the orchestration so you don't have the overhead of running the orchestration every time if it doesn't need to. The different branches of the decision have the Action set on them or not to run the orchestration workflow.

    That's assuming you don't need the orchestration to run every time and are just trying to avoid a single step within the orchestration.
Reply
  • I think the idea of using a field is sound. One thing you might look at is in your App Workflow use a decision step that will test your field value and then have it run the orchestration or just skip the orchestration so you don't have the overhead of running the orchestration every time if it doesn't need to. The different branches of the decision have the Action set on them or not to run the orchestration workflow.

    That's assuming you don't need the orchestration to run every time and are just trying to avoid a single step within the orchestration.
Children