History Time to Live on respective Process definitions

Hi Team,

I have a question regarding History Time To Live behavior in Platform 7 Community. Edition.

When i define the “historyTimeToLive” from property file/yaml and then after the deployment of bpmn if execute any worklfow then all process instances and variables etc in respective history table has this column"removal_time_" populated based on the TTL provided by me.

Please note i have not specified cleanUpStrategy and hence as per document default is “RemovalTimeBased” and hence “removal_time_” has been populated for latest version executed processes.

I have also provided same property “History Time To Live” at individual BPMN level from property panel using Camunda modeler and have deployed that particular BPMN and executed the same after deployment. For that particular instance in history table i dont see the “removal_time_” populated.

My question is that is there any difference between default “cleanupStrategy” when we set the TTL at property File/Yaml as opposed to when we place it on individual process definition via Camunda Modeller?

It seems to me like since “removal_time_” is not populating for individual process def level TTL it means its taking it as “endTimeBased” by default.

Please enlighten me. I have a use case where i would need certain process instances to have diff TTL (Removal time based) and majority as another TTL (Removal time based).

Sharing one observation here after internal digging and sample tests:

  1. TTL on BPMN level is “Removal Time Based”.
  2. If we have the “historyTimeToLive” from property file/yaml and also have one of the child process “TTL” via the BPMN modeller properties panel then what i observed is it doesnt work and it only picks the Global i.e property file/yaml into consideration.
  3. I removed from property file/yaml and then put the TTL only on BPMN properties from modeller and it was calculating the “removal_time_”.

So it seems like “TTL” from properties don’t work in conjunction with the “historyTimeToLive” from property file/yaml.

Any comments on this?

Is there any way we can have different TTL for different bpmn called from same parent BPMN? Without ofcourse individually defining TTL on each BPMN as we have hundreds of such flows and we want specific behaviour for few while a common behaviour for rest 90% of it.

Hi @Sanjay_Vyas,

what you observed is not aligned with the documentation here: History and Audit Event Log | docs.camunda.org, esp the last paragraph.

It could be the case you found an issue in the process engine. The best way to handle it is to provide a reproduceable example, maybe based on this unit test template: GitHub - camunda/camunda-engine-unittest: Unit test template project for camunda engine

Hope this helps, Ingo