How to separate camunda's DB schema from application-schema ?

598 views
Skip to first unread message

Jörg Winter

unread,
May 25, 2015, 5:13:29 PM5/25/15
to camunda-...@googlegroups.com
Hi,

In the recommended wildfly-installation, the camunda-entities seem to be in:

wildfly-8.2.0.Final/modules/org/camunda/bpm/camunda-engine/main/camunda-engine-7.2.0.jar:/org/camunda/bpm/engine/impl/persistence

...which I guess makes them 'available' to any deployed application (which is using camunda ofcourse).

How can I have my App's entities managed by a separate persistence-unit ?
Do I have to specify all camunda-entities in one persistence unit ?
Listing all classes seems not right, specifying an entity-jar is only for EAR deployments...

What I want is:
persistence-unit "A" having _only_ camunda entities, so the db tables only have "ACT_..." tables, managing the process(es)
persistence-unit "B" having _only_ my App's entities (and mapped tables)

Best,
Joerg

r.brae...@gmail.com

unread,
May 26, 2015, 2:07:44 AM5/26/15
to camunda-...@googlegroups.com
Hello Jörg,

the persistent classes from camunda BPM aren't JPA entities and therefore they won't be managed by JPA and associated to a persistence-unit. The engine uses MyBatis for persistence[1], which isn't aware of persistence units.

If you want to separate your classes from the camunda ones you can specify different datasources. In the Wildfly distribution you should see by default the "ExampleDS" and the "ProcessEngine" datasource. If you only use one of them for your classes and the other one for the processes you should achieve the same.

Cheers,
Ronny


[1] http://stage.docs.camunda.org/guides/user-guide/#process-engine-database-configuration
Reply all
Reply to author
Forward
0 new messages