Uploaded image for project: 'WildFly WIP'
  1. WildFly WIP
  2. WFWIP-428

s2i v2 problems making work applications with drivers

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • OpenShift
    • None

    Description

      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&gt;org.h2.jdbcx.JdbcDataSource</xa-datasource-class&gt;
                          </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
      

      Attachments

        1. database-eap74-1-build-sti-build.log
          463 kB
          Martin Choma
        2. db-1-47czt-db.log
          29 kB
          Martin Choma

        Activity

          People

            jdenise@redhat.com Jean Francois Denise
            mchoma@redhat.com Martin Choma
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: