Impossible to Configure JBoss 6.4 with PostgreSQL as Datasource
juleshoueto May 25, 2017 8:33 PMHello all,
I am trying to configure JBoss BRMS 6.4 to use PostgreSQL as datasource. JBoss BRMS 6.4 is using JBoss EAP 6.4 as container.
I am using postgresql-9.4-1202.jdbc42.jar as JDBC driver. My operating system is Centos 7
The part in bold are the lines that I add in the standalone.xml file to make JBoss use PostgresSQL as datasource :
I add this two lines in the system-properties
<system-properties>
<property name="org.kie.example" value="true"/>
<property name="org.jbpm.designer.perspective" value="ruleflow"/>
<property name="designerdataobjects" value="false"/>
<property name="org.jbpm.server.ext.disabled" value="true"/>
<property name="org.jbpm.ui.server.ext.disabled" value="true"/>
<property name="org.uberfire.nio.git.daemon.host" value="0.0.0.0"/>
<property name="org.uberfire.nio.git.ssh.host" value="0.0.0.0"/>
<property name="org.kie.server.location" value="http://orc-brms3:8080/kie-server/services/rest/server"/>
<property name="org.kie.server.controller" value="http://orc-brms3:8080/business-central/rest/controller"/>
<property name="org.kie.server.controller.user" value="brms"/>
<property name="org.kie.server.controller.pwd" value="P@ssw0rd"/>
<property name="org.kie.server.user" value="brms"/>
<property name="org.kie.server.pwd" value="P@ssw0rd"/>
<property name="org.kie.server.id" value="default-kieserver"/>
<property name="jboss.as.management.blocking.timeout" value="700"/>
<property name="org.kie.server.persistence.ds" value="java:jboss/datasources/PostgresqlDS"/>
<property name="org.kie.server.persistence.dialect" value="org.hibernate.dialect.PostgreSQLDialect"/>
</system-properties>
<datasources>
<datasource jndi-name="java:jboss/datasources/ExampleDS" pool-name="ExampleDS" enabled="false" use-java-context="true">
<connection-url>jdbc:h2:mem:test;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE</connection-url>
<driver>h2</driver>
<security>
<user-name>sa</user-name>
<password>sa</password>
</security>
</datasource>
<datasource jndi-name="java:jboss/datasources/PostgresqlDS" pool-name="PostgresqlDS" enabled="true">
<connection-url>jdbc:postgresql://192.168.56.16:5432/jbpm</connection-url>
<driver>postgresql-9.4-1202.jdbc42.jar</driver>
<security>
<user-name>jbpm</user-name>
<password>jbpm</password>
</security>
</datasource>
<drivers>
<driver name="h2" module="com.h2database.h2">
<xa-datasource-class>org.h2.jdbcx.JdbcDataSource</xa-datasource-class>
</driver>
<driver name="postgres" module="org.postgres">
<driver-class>org.postgresql.Driver</driver-class>
</driver>
</drivers>
</datasources>
This is the content of my module.xml that i creat in : /EAP_HOME/modules/org/postgres/main/module.xml
<?xml version="1.0" ?>
<module xmlns="urn:jboss:module:1.1" name="org.postgres">
<resources>
<resource-root path="postgresql-9.4-1202.jdbc42.jar"/>
</resources>
<dependencies>
<module name="javax.api"/>
<module name="javax.transaction.api"/>
</dependencies>
</module>
But when I execute the ./standalone.sh script I receive this Error :
00:28:36,709 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) JBAS014612: Operation ("add") failed - address: ([
("subsystem" => "datasources"),
("data-source" => "PostgresqlDS")
]) - failure description: {"JBAS014771: Services with missing/unavailable dependencies" => [
"jboss.data-source.java:jboss/datasources/PostgresqlDS is missing [jboss.jdbc-driver.postgresql-9_4-1202_jdbc42_jar]",
"jboss.driver-demander.java:jboss/datasources/PostgresqlDS is missing [jboss.jdbc-driver.postgresql-9_4-1202_jdbc42_jar]"
]}
00:28:36,711 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) JBAS014612: Operation ("enable") failed - address: ([
("subsystem" => "datasources"),
("data-source" => "PostgresqlDS")
]) - failure description: {"JBAS014879: One or more services were unable to start due to one or more indirect dependencies not being available." => {
"Services that were unable to start:" => [
"jboss.data-source.reference-factory.PostgresqlDS",
"jboss.naming.context.java.jboss.datasources.PostgresqlDS"
],
"Services that may be the cause:" => ["jboss.jdbc-driver.postgresql-9_4-1202_jdbc42_jar"]
Thank you for your time and helping me.
So please if you think that I am are the wrong place for expecting solution, kindly indicate the correct forum.