Uploaded image for project: 'Cloud Enablement'
  1. Cloud Enablement
  2. CLOUD-3367

[eap72-openjdk11-openshift-rhel8] Change in behaviour of DEFAULT_JOB_REPOSITORY environment variable

XMLWordPrintable

    • Workaround Exists
    • Hide

      Point DEFAULT_JOB_REPOSITORY to the value of DB_SERVICE_PREFIX_MAPPING rather than the key, e.g. if DB_SERVICE_PREFIX_MAPPING=testdb-postgresql=TESTDB_POSTGRESQL, TIMER_SERVICE_DATA_STORE=TESTDB_POSTGRESQL will work.

      Show
      Point DEFAULT_JOB_REPOSITORY to the value of DB_SERVICE_PREFIX_MAPPING rather than the key, e.g. if DB_SERVICE_PREFIX_MAPPING=testdb-postgresql=TESTDB_POSTGRESQL , TIMER_SERVICE_DATA_STORE=TESTDB_POSTGRESQL will work.

      Suppose a deployment built on eap72-openjdk11-openshift-rhel8 image with the following environment variables that assured that the server would point batch subsystem job repository towards java:jboss/datasources/postgres datasource previously (eap72-openshift images):

      ...
              - env:             - name: TESTDB_POSTGRESQL_XA_CONNECTION_PROPERTY_URL
                    value: 'jdbc:postgresql://testdb-postgresql:5432/testdb'
                  - name: DB_SERVICE_PREFIX_MAPPING
                    value: testdb-postgresql=TESTDB_POSTGRESQL
                  - name: MQ_TOPICS
                    value: test
                  - name: MQ_QUEUES
                    value: test
                  - name: TESTDB_POSTGRESQL_PASSWORD
                    value: testpwd
                  - name: TESTDB_POSTGRESQL_DATABASE
                    value: testdb
                  - name: TESTDB_POSTGRESQL_DRIVER
                    value: postgresql
                  - name: TESTDB_POSTGRESQL_JNDI
                    value: 'java:jboss/datasources/postgres'
                  - name: DEFAULT_JOB_REPOSITORY
                    value: testdb-postgresql
                  - name: JAVA_OPTS_APPEND
                    value: '-Ddatasource=java:jboss/datasources/postgres'
                  - name: TESTDB_POSTGRESQL_USERNAME
                    value: testuser
      ...

      EAP does not have any jdbc-job-repository in /subsystem=batch-jberet configured. This is a change compared to eap72-openshift image, where the JDBC job repository gets properly configured.

      eap72-openjdk11-openshift-rhel8
      [standalone@localhost:9990 /] /subsystem=batch-jberet:read-resource
      /subsystem=batch-jberet:read-resource
      {
          "outcome" => "success",
          "result" => {
              "default-job-repository" => "in-memory",
              "default-thread-pool" => "batch",
              "restart-jobs-on-resume" => true,
              "security-domain" => undefined,
              "in-memory-job-repository" => {"in-memory" => undefined},
              "jdbc-job-repository" => undefined,
              "thread-factory" => undefined,
              "thread-pool" => {"batch" => undefined}
          }
      }
      
      eap72-openshift
      [standalone@localhost:9990 /] /subsystem=batch-jberet:read-resource
      {
          "outcome" => "success",
          "result" => {
              "default-job-repository" => "testdb_postgresql-TESTDB_POSTGRESQL",
              "default-thread-pool" => "batch",
              "restart-jobs-on-resume" => true,
              "security-domain" => undefined,
              "in-memory-job-repository" => {"in-memory" => undefined},
              "jdbc-job-repository" => {"testdb_postgresql-TESTDB_POSTGRESQL" => undefined},
              "thread-factory" => undefined,
              "thread-pool" => {"batch" => undefined}
          }
      }
      
      

              kwills@redhat.com Ken Wills
              kwills@redhat.com Ken Wills
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated: