cancel
Showing results for 
Search instead for 
Did you mean: 

Is it possible to modify historic process instance data?

mkolas
Champ in-the-making
Champ in-the-making
I've received a request to be able to modify process variables on completed process instances. A common scenario is that a user somewhere along the workflow has filled in a field incorrectly and it was not caught immediately- long after the instance is dead and buried, someone looking at reports might notice that and want to change it.

We've debated a few different ways to be able to do this (such as having a perpetual end task as opposed to having the instance ever complete), but I was looking for a sanity check to make sure I'm not missing something obvious.

With a quick glance at the Java classes…. on the RuntimeService, I see a setVariable method that can be used to modify process variables, but nothing from the HistoryService. Are we SOL here, or is there anything hidden away that I might be able to access?
2 REPLIES 2

martin_grofcik
Confirmed Champ
Confirmed Champ
Hi,

There is not API to change HistoryService data. The purpose of HistoryService is to provide the data which were present at the time when process instance was executed (e.g logs auditrail…).
I can agree that values can change in time. I would suggest to do not store such a information in a process.

Regards
Martin

mkolas
Champ in-the-making
Champ in-the-making
Unfortunately we're using Activiti in Alfresco so we're kind of bound to use process variables in that manner- there's not really a whole ton of leeway in how we store our data. There's always the opportunity to sidecar the information in a contentless object or something of that nature, but then the metadata is not easily accessible from Alfresco's Workflow Details page.

Thanks for your feedback nevertheless though.

Max