cancel
Showing results for 
Search instead for 
Did you mean: 

changing the historyLevel

heymjo
Champ on-the-rise
Champ on-the-rise
Hi,

An application is running activiti with historyLevel set to the default 'full'. When the application now wants to change the historyLevel to the default 'audit' it is not enough to make the change on the process engine configuration, you get this error:


<03-May-2012 11:50:23 o'clock CEST> <Warning> <Deployer> <BEA-149078> <Stack trace for message 149004
weblogic.application.ModuleException: :org.activiti.engine.ActivitiException:Activiti database problem: historyLevel mismatch: configuration says 2 and database says 3

When i then do


UPDATE act_ge_property SET value_ = 2 WHERE name_ = 'historyLevel'

it works again.

Why is the historyLevel hardcoded in the database ? AFAICT it is only the engine that writes to the history tables, and that engine is configured on the java level already so no need to go and check against a configuration table.

Thoughts ?
2 REPLIES 2

trademak
Star Contributor
Star Contributor
Hi,

Interesting question, we had some internal discussion about it a while ago.
There can be potential problems when you do a hot switch of the history setting. Therefore the database change is also needed.
But since it's only history data, I would not expect that much potential problems. But we would need some decent unit tests to prove this I guess.

Best regards,

heymjo
Champ on-the-rise
Champ on-the-rise
You mean hot-switch as in changing the processengineconfiguration at runtime ? I can understand how this can cause problems, but it's not something i think many people would want to do.