Rollback transition file tidyup

Rollback transition file tidyup

Chris-strickland
Contributor Contributor
869 Views
4 Replies
Message 1 of 5

Rollback transition file tidyup

Chris-strickland
Contributor
Contributor

Hi, 

 

Is it possible to create a job processor task which runs when a file is rolled back a Revision?

 

I think the answer to this question is no, but its worth a try...

 

The reason I ask is that we have Job server create pdf's etc when drawings are released, but on some occasions is is necessary to roll back and retract the released part/drawing. unfortunately this leaves an orphan pdf in the vault - it was created by the job server when the part and drawing were released, but the revision which it represents no longer exists. This can cause confusion!

 

It would be nice if the job server could be tasked with tidying these (attached) files up when a rollback transition occurs. 

0 Likes
870 Views
4 Replies
Replies (4)
Message 2 of 5

ihayesjr
Community Manager
Community Manager

HI Chris,

 

At this time we don't not have an out-of-the-box way of doing what you are asking. I would recommend that you place this into our Ideas board for consideration.

 

In the mean time, our API does allow you to create custom jobs that are triggered on lifecycle transition which you may be able to accomplish this.




Irvin Hayes Jr
Principal Product Manager
Autodesk, Inc.

Vault - Under the Hood Blog
0 Likes
Message 3 of 5

Chris-strickland
Contributor
Contributor

Hi Irvin,

 

Could I just clarify, you say "our API does allow you to create custom jobs...", do you mean using the lifecycle event editor to add jobs to transitions? If so, I know about that, we are using Coolorange powerjobs to add custom jobs to the transitions, the problem is that when I add a job to the transition "Released >> Review" the job is not picked up by the job server when I use the action "roll back lifecycle state change". Is it possible to detect the lifecycle transition associated with a rollback action?

 

Thanks

Chris

0 Likes
Message 4 of 5

bill.schwerin
Autodesk
Autodesk

  In theory, you can create a custom job handler that does your tidy up code. 

 

  You problem is in creating the job.  You can't use the Released-> Review transition because rollback isn't really a transition.  Transitions happen because of state change.  People would be upset if we enforced transition rules on rollback.

 

  You should be able to use event handlers.... when the rollback event happens, queue add a tidyup job to the queue.

 

Bill

 

 

0 Likes
Message 5 of 5

Chris-strickland
Contributor
Contributor

Thanks Bill, 

 

I will have to investigate this further, it's a little more complex than I was hoping!

 

Do you think that it would be feasible to have an special event (generic to any rollback operation) which fired on the "rollback Transition", you could then create a job which is triggered on any rollback operation, the Job script itself would have to use some logic to work out what the old and new states are and decide if it needs to do anything.

 

Thanks for your help.

Chris

0 Likes