Details
Description
1) Create tables manually using the Activiti DDLs
2) Run Activiti in ProcessEngineConfiguration.DB_SCHEMA_UPDATE_FALSE mode -> exception is thrown because historyLevel property is not in DB
3) We overrode dbSchemaCheckVersion() to make this work (see below)
@Override
public void dbSchemaCheckVersion() {
if (isEngineTablePresent()) {
Integer configuredHistoryLevel = Context.getProcessEngineConfiguration().getHistoryLevel();
PropertyEntity historyLevelProperty = selectById(PropertyEntity.class, "historyLevel");
if (historyLevelProperty == null) {
PropertyEntity property = new PropertyEntity("historyLevel", Integer.toString(configuredHistoryLevel));
insert(property);
}
}
super.dbSchemaCheckVersion();
}
We verified the error and the fix using Oracle DB and DDLs.
Issue Links
- duplicates
-
ACT-1333
Fix upgrade script
-
Activity
Bernd Ruecker (camunda)
made changes -
| Field | Original Value | New Value |
|---|---|---|
| Component/s | Engine [ 14460 ] |
Tom Baeyens
made changes -
| Status | Open [ 1 ] | Closed [ 6 ] |
| Resolution | Not A Bug [ 6 ] |
Etienne Studer
made changes -
| Resolution | Not A Bug [ 6 ] | |
| Status | Closed [ 6 ] | Reopened [ 4 ] |
Tom Baeyens
made changes -
| Assignee | Tom Baeyens [ tombaeyens ] | |
| Fix Version/s | 5.11 [ 18342 ] |
Tom Baeyens
made changes -
Tom Baeyens
made changes -
| Status | Reopened [ 4 ] | Resolved [ 5 ] |
| Assignee | Tom Baeyens [ tombaeyens ] | Frederik Heremans [ frederikheremans ] |
| Resolution | Fixed [ 1 ] |