cancel
Showing results for 
Search instead for 
Did you mean: 

Doing by design

martin_grofcik
Confirmed Champ
Confirmed Champ
6 REPLIES 6

martin_grofcik
Confirmed Champ
Confirmed Champ
In fact it is Design by doing (opposite direction).

jbarrez
Star Contributor
Star Contributor
It's an idea that I also wanted to do once I find time 😉
The hard part is finding a good relationship/reference model for the various deploymens that get created along the way that fits within the Activiti architecture/API's.

martin_grofcik
Confirmed Champ
Confirmed Champ
Hi Joram,

The hard part is finding a good relationship/reference model for the various deploymens that get created along the way that fits within the Activiti architecture/API's.

Could you describe it more? (example….)

regards
Martin

jbarrez
Star Contributor
Star Contributor
Sure: there are a few options here as how to handle the 'previous' process definition (more specifically what the upgradeProcessInstanceDefinitionVersion() method does):

- Overwite the existing process definition and set the process instance to this one. In this case the change must be possible, as in there must exist a matching element in both process definition
- Explicitely map. Do a mapping from activities to the new activities (A->A, B->C, etc)

Which is clear, I think. But there are now two deployments, in both cases, and this needs to be reflected in the audit history too.
So my comment was more referring to that: how would the 'dynamicity' be captured, both in runtime and history.

But both options are born from the fact that deployments and process definitions are static in Activiti (and rightly so, for performance reasons). I wonder if there are different mechanisms possible … where that is not needed, and where the process definition is really fluid … but that would mean a different implementation of some of the core parts … or maybe not.

Stuff to think about!

martin_grofcik
Confirmed Champ
Confirmed Champ
Hi Joram,

But there are now two deployments, in both cases, and this needs to be reflected in the audit history too.
The command to set process definition in the process instance updates history too. (I read something like that in the code - but I did not check it.

Yes, let's think about.

Regards
Martin

jbarrez
Star Contributor
Star Contributor
Yes, it does I believe. But I'd also like to capture the fact it's being done by a 'dynamic operation', so that one can reconstruct what happened exactly from the history (which is not the case if we simply use what's there now).