Show Table of Contents
Chapter 3. Special setups
3.1. Setting up Persistence for Business Central
BPM Suite is configured to use an example datasource with Java Naming and Directory Interface (JNDI) name
java:jboss/datasources/ExampleDS. For Business Central, this example datasource is located in the file business-central.war/WEB-INF/classes/META-INF/persistence.xml.
If you want to configure BPM Suite to use an external database, make the following changes. For file
business-central.war/WEB-INF/classes/META-INF/persistence.xml:
- Install the respective Java Database Connectivity (JDBC) driver using modular approach for easy subsequent configuration (see EAP 6 documentation).
- Create a new datasource according to the example in EAP 6 documentation, section 6.7.1. Example PostgreSQL Datasource. This is the default used H2 database specific datasource configuration:
<subsystem xmlns="urn:jboss:domain:datasources:1.1"> <datasources> <datasource jndi-name="java:jboss/datasources/ExampleDS" pool-name="ExampleDS" enabled="true" use-java-context="true"> <connection-url>jdbc:h2:mem:test;DB_CLOSE_DELAY=-1</connection-url> <driver>h2</driver> <security> <user-name>sa</user-name> <password>sa</password> </security> </datasource> <drivers> <driver name="h2" module="com.h2database.h2"> <xa-datasource-class>org.h2.jdbcx.JdbcDataSource</xa-datasource-class> </driver> </drivers> </datasources> - Use the JNDI name of the datasource to update the following entry inside the
persistence.xmlfile, which is by default set to this entry.<jta-data-source>java:jboss/datasources/ExampleDS</jta-data-source>
Important
When configuring your datasource, make sure to enable JTA (typically, by addingjta="true"to thedatasourcetag). - Replace the following text with the appropriate database specific hibernate dialect name.
<property name="hibernate.dialect" value="org.hibernate.dialect.H2Dialect" />
For example, for an Oracle Database Express Edition 11g, it would be:<property name="hibernate.dialect" value="org.hibernate.dialect.Oracle10gDialect" />

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.