Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

...

Know exceptions when version mismatch:

Code Block
java
java

Caused by: org.activiti.engine.ActivitiException: couldn't parse 'XXX.bpmn20.xml': Content is not allowed in prolog.
	at org.activiti.engine.impl.util.xml.Parse.execute(Parse.java:136)
	at org.activiti.engine.impl.bpmn.parser.BpmnParse.execute(BpmnParse.java:160)
	at org.activiti.engine.impl.bpmn.deployer.BpmnDeployer.deploy(BpmnDeployer.java:76)
	at org.activiti.engine.impl.db.DbRepositorySession.deploy(DbRepositorySession.java:65)
	at org.activiti.engine.impl.db.DbRepositorySession.resolveProcessDefinition(DbRepositorySession.java:195)

...

When handling CLOB and BLOB's on postgres, default CLOB MyBatis type cannot be used, BINARY should be used instead.

Code Block
xml
xml

<result property="bytes" column="BYTES_" jdbcType="BINARY"/> 

This exception occurs when type not handled properly

Code Block
java
java

## Error querying database.  Cause: org.postgresql.util.PSQLException: Bad value for type long : XXXXXXX

*Be sure to check all statements that have postgres-specific counterparts (or any other DB) aren't referenced from within other mapped statements. These aren't aware of our database-specific bahaviour. Here you
should create an postgres-specific statement for the statement using it. Eg. association-select for byte-array entity using selectByteArrayById_postgres: *

Code Block
xml
xml


<resultMap id="historicVariableUpdateResultMap" extends="historicDetailResultMap" type="org.activiti.engine.impl.history.HistoricVariableUpdateEntity">
    <result property="name" column="NAME_" javaType="String" jdbcType="VARCHAR" />
    ...
    <result property="longValue" column="LONG_" jdbcType="BIGINT" />
    <association property="byteArrayValue" 
                 column="BYTEARRAY_ID_" 
                 javaType="org.activiti.engine.impl.runtime.ByteArrayEntity" 
                 select="selectByteArrayById" />
</resultMap>
<resultMap id="historicVariableUpdateResultMap_postgres" extends="historicDetailResultMap" type="org.activiti.engine.impl.history.HistoricVariableUpdateEntity">
    <result property="name" column="NAME_" javaType="String" jdbcType="VARCHAR" />
    ....
    <result property="longValue" column="LONG_" jdbcType="BIGINT" />
    <association property="byteArrayValue" 
                 column="BYTEARRAY_ID_" 
                 javaType="org.activiti.engine.impl.runtime.ByteArrayEntity" 
                 select="selectByteArrayById_postgres" />
  </resultMap>

Tuning history

If you're using history, it can be tuned by adding the following index (oracle dialect)

create index ACT_IDX_HI_EXEC_ACT_ID on ACT_HI_ACTINST (EXECUTION_ID_, ACT_ID_)
  tablespace PRODF;

If you think this index should be added to the installation scripts, vote for ACT-1231