History clean up for flowable DMN Table

Hi All, I am trying to find the way for history clean up for DMN HISTORY Table ACT_DMN_HI_DECISION_EXECUTION if anyone has any suggestions please post here.

If you would like to use java api use can use the query to obtain the historic executions like
dmnHistoryService.createHistoricDecisionExecutionQuery().list();
Then you can use the same to delete them,
dmnHistoryService.deleteHistoricDecisionExecution(dmnHistoricDecisionExecutionId);

1 Like

Hi,

in addition to the previous reply…

We’re working on a feature that will automatically delete all process / case instances and related data (like DMN executions) executed after a specify date / time.
Also; you can also delete entries directly in the mentioned table. There should not be any side effects to this.

1 Like

Thanks for you reply however I am not able to find delete api in dmnHistoryService api. Do you have any suggestions?

Hi, yes there is no delete historic decision execution rest api as i know.
You could use a Script Task along with the java api methods to cleanup, or a clean on database directly.
Or you can write a wrapper rest api and do the java call.