cancel
Showing results for 
Search instead for 
Did you mean: 

Externalizing HistoryLevel

rufini
Champ in-the-making
Champ in-the-making
Hi:

I would like to externalize the Activiti's history level.

I'm seeing that there's some database configuration (in ACT_GE_PROPERTY, 'historyLevel', '2', '1' ) and a property set on bean org.activiti.spring.SpringProcessEngineConfiguration <property name="history" value="audit" />

I tryied to delete the database record, but it's required at start. And ommitting the property, defaults it to "audit". So, if both properties doesn't match, I get an

org.activiti.engine.ActivitiException: Activiti database problem: historyLevel mismatch: configuration says 2 and database says 3


There's a way to configure it in 1 place only?

Thanks!
rufini
3 REPLIES 3

trademak
Star Contributor
Star Contributor
You should be able to set the history level in the configuration file without needing to deal with the database value.

Best regards,

rufini
Champ in-the-making
Champ in-the-making
Thanks for your reply, trademak.

If I change my activiti-context file, I get an

org.activiti.engine.ActivitiException: Activiti database problem: historyLevel mismatch: configuration says 1 and database says 2

Where should I change it?

Thanks!

trademak
Star Contributor
Star Contributor
Hi,

You are right, to change the history level you have to change the values in both the database and the configuration file.
We've done this because updating the history level is not something you want to do overnight. But it's not very well documented right now.
The history levels you can choose from are :

public static final int HISTORYLEVEL_NONE = 0;
public static final int HISTORYLEVEL_ACTIVITY = 1;
public static final int HISTORYLEVEL_AUDIT = 2;
public static final int HISTORYLEVEL_FULL = 3;

Hope this helps you with your issue.

Best regards,