I have a legacy dispatch that kicks in when we put our models"under revision”, it increases a variable by +1 since it is not apparently possible with a normal transition action.
I rewrote the dispatch, to handle its limitation of running every time the file state was changed, independently from the transition direction.
e.g. from “approved” to “under revision” was handled the same way as going from "waiting for approval” back to “under revision”
I worked around that limitation with a variable check, if the difference between two variables is already 1 I skip the +1 increase action, otherwise I increase the variable by 1 and add a comment in the file history to record that dispatch took action.
This is why I know it failed to run for a certain file: there is no comment in the file history about the dispatch action. The user that reported it noticed the variable in the datacard was not increased by 1 as it should, after the transition, he remembers to have changed the state from the SW PDM addin and eventually there was an error dialog, but the user is not sure and does not remember well what happened.
I tried to change the state for the same file from our test server, the dispatch kicked in correctly, and there is a comment in the file history recording the dispatch action. I do not know what to think anymore… was dispatch crashing on that PDM client? Is dispatch not robust enough to be trusted?
I tried multiple times with that single file, rolling back and doing the state change, again and again, and dispatch never failed.
I just cannot think of a way to make dispatch fail on purpose. It could fail if the file cannot be checked out, before the variable is increased, but it is unlikely the case here since the user should have the file checked in as approved state, and he has the rights to make the transition to “under revision”, check out the fuke and edit it.