-
Bug
-
Resolution: Done
-
Major
-
None
We have applications which contain database drivers (in attachment).
Build is OK, but WF pod does not start with
"WFLYCTL0180: Services with missing/unavailable dependencies" => [
"jboss.driver-demander.java:jboss/datasources/testdb_postgresql is missing [jboss.jdbc-driver.postgresql]",
"org.wildfly.data-source.testdb_postgresql-TESTDB_POSTGRESQL is missing [jboss.jdbc-driver.postgresql]"
]
This is what I can see in configuration
<xa-datasource jndi-name="java:jboss/datasources/testdb_postgresql" pool-name="testdb_postgresql-TESTDB_POSTGRESQL" enabled="true" use-java-context="true" statistics-enabled="${wildfly.datasources.statistics-enabled:${wildfly.statistics-enabled:false}}">
<xa-datasource-property name="DatabaseName">
testdb
</xa-datasource-property>
<xa-datasource-property name="ServerName">
172.122.250.134
</xa-datasource-property>
<xa-datasource-property name="PortNumber">
5432
</xa-datasource-property>
<driver>postgresql</driver>
<security>
<user-name>testuser</user-name>
<password>testpwd</password>
</security>
<validation>
<valid-connection-checker class-name="org.jboss.jca.adapters.jdbc.extensions.postgres.PostgreSQLValidConnectionChecker"/>
<validate-on-match>true</validate-on-match>
<background-validation>false</background-validation>
<exception-sorter class-name="org.jboss.jca.adapters.jdbc.extensions.postgres.PostgreSQLExceptionSorter"/>
</validation>
</xa-datasource>
<drivers>
<driver name="h2" module="com.h2database.h2">
<xa-datasource-class>org.h2.jdbcx.JdbcDataSource</xa-datasource-class>
</driver>
</drivers>
</datasources>
Really postgresql driver is not there. Although In build log there are messages like
if (outcome == success) of /subsystem=datasources/jdbc-driver=postgresql:read-resource
echo "Cannot add the driver with name postgresql. There is a driver with the same name already configured." >> ${error_file}
quit
else
/subsystem=datasources/jdbc-driver=postgresql:add(driver-name="postgresql", driver-module-name="org.postgresql", driver-xa-datasource-class-name="org.postgresql.xa.PGXADataSource", driver-class-name="org.postgresql.Driver")
end-if
There is module for postgresql driver
ls /opt/server/modules/org/postgresql/main/ README.md module.xml postgresql-jdbc.jar