diff --git a/os.kieserver.launch/added/kieserver-config.sh b/os.kieserver.launch/added/kieserver-config.sh index 82641340..b9eaa0fe 100755 --- a/os.kieserver.launch/added/kieserver-config.sh +++ b/os.kieserver.launch/added/kieserver-config.sh @@ -391,6 +391,9 @@ function setKieServerEnv() { KIE_SERVER_OPTS="${KIE_SERVER_OPTS} -Dorg.kie.server.persistence.ds=${KIE_SERVER_PERSISTENCE_DS}" KIE_SERVER_OPTS="${KIE_SERVER_OPTS} -Dorg.kie.server.persistence.tm=${KIE_SERVER_PERSISTENCE_TM}" fi + if [ "x${KIE_SERVER_PERSISTENCE_SCHEMA}" != "x" ]; then + KIE_SERVER_OPTS="${KIE_SERVER_OPTS} -Dorg.kie.server.persistence.schema=${KIE_SERVER_PERSISTENCE_SCHEMA}" + fi KIE_SERVER_OPTS="${KIE_SERVER_OPTS} -Dorg.kie.server.repo=${KIE_SERVER_REPO}" KIE_SERVER_OPTS="${KIE_SERVER_OPTS} -Dorg.optaplanner.server.ext.disabled=${KIE_SERVER_BRP_DISABLED}" if [ "x${KIE_SERVER_MGMT_DISABLED}" != "x" ]; then diff --git a/os.kieserver.launch/added/kieserver-setup.sh b/os.kieserver.launch/added/kieserver-setup.sh index 053f68b2..dcd9f345 100644 --- a/os.kieserver.launch/added/kieserver-setup.sh +++ b/os.kieserver.launch/added/kieserver-setup.sh @@ -31,25 +31,81 @@ function filterKieJmsFile() { } function filterQuartzPropFile() { + + local QUARTZ_DELEGATE_CLASS="org.quartz.impl.jdbcjobstore.StdJDBCDelegate" + local DEFAULT_JNDI + local DB_TYPE + quartzPropFile="${1}" if [ -e ${quartzPropFile} ] ; then - if [[ "${KIE_SERVER_PERSISTENCE_DIALECT}" == "org.hibernate.dialect.MySQL"* ]]; then - sed -i "s,org.quartz.jobStore.driverDelegateClass=,org.quartz.jobStore.driverDelegateClass=org.quartz.impl.jdbcjobstore.StdJDBCDelegate," ${quartzPropFile} - quartzDriverDelegateSet="true" - elif [[ "${KIE_SERVER_PERSISTENCE_DIALECT}" == "org.hibernate.dialect.PostgreSQL"* ]]; then - sed -i "s,org.quartz.jobStore.driverDelegateClass=,org.quartz.jobStore.driverDelegateClass=org.quartz.impl.jdbcjobstore.PostgreSQLDelegate," ${quartzPropFile} - quartzDriverDelegateSet="true" + + + # get the first db configuration using legacy datasource configuration: + if [ "x${DB_SERVICE_PREFIX_MAPPING}" != "x" ]; then + local serviceMappingName=${DB_SERVICE_PREFIX_MAPPING%%,*} + local prefix=${serviceMappingName#*=} + DEFAULT_JNDI=$(find_env "${prefix}_JNDI") fi - if [ "x${DB_JNDI}" != "x" ]; then - sed -i "s,org.quartz.dataSource.managedDS.jndiURL=,org.quartz.dataSource.managedDS.jndiURL=${DB_JNDI}," ${quartzPropFile} + # get the first db configuration using DATASOURCES env: + if [ "x${DATASOURCES}" != "x" ]; then + local prefix="${DATASOURCES%%,*}" + DEFAULT_JNDI=$(find_env "${prefix}_JNDI") + fi + + if [ "x${DEFAULT_JNDI}" != "x" ]; then quartzManagedJndiSet="true" fi if [ "x${QUARTZ_JNDI}" != "x" ]; then - sed -i "s,org.quartz.dataSource.notManagedDS.jndiURL=,org.quartz.dataSource.notManagedDS.jndiURL=${QUARTZ_JNDI}," ${quartzPropFile} quartzNotManagedJndiSet="true" fi + + if [[ "${KIE_SERVER_PERSISTENCE_DIALECT}" == "org.hibernate.dialect.MySQL"* ]]; then + quartzDriverDelegateSet="true" + DB_TYPE="MYSQL" + elif [[ "${KIE_SERVER_PERSISTENCE_DIALECT}" == "org.hibernate.dialect.PostgreSQL"* ]]; then + QUARTZ_DELEGATE_CLASS="org.quartz.impl.jdbcjobstore.PostgreSQLDelegate" + quartzDriverDelegateSet="true" + DB_TYPE="POSTGRESQL" + elif [[ "${KIE_SERVER_PERSISTENCE_DIALECT}" == *"Oracle"* ]]; then + log_warning "For Oracle 10G use the org.jbpm.persistence.jpa.hibernate.DisabledFollowOnLockOracle10gDialect hibernate dialect to avoid frequent Hibernate warning HHH000444 message in the logs." + QUARTZ_DELEGATE_CLASS="org.quartz.impl.jdbcjobstore.oracle.OracleDelegate" + # Oracle classes needs to be accessible by the quartz, in this case oracle driver or module needs to be added on jboss-deployment-structure.xml file + if [ "x${QUARTZ_DRIVER_MODULE}" != "x" ]; then + sed -i "s|<\!--EXTRA_DEPENDENCY-->|\n <\!--EXTRA_DEPENDENCY-->|" $JBOSS_HOME/standalone/deployments/kie-server.war/WEB-INF/jboss-deployment-structure.xml + else + log_warning "QUARTZ_DRIVER_MODULE env not set. Quartz might not work properly." + fi + quartzDriverDelegateSet="true" + DB_TYPE="ORACLE" + elif [[ "${KIE_SERVER_PERSISTENCE_DIALECT}" == "org.hibernate.dialect.SQLServer"* ]]; then + QUARTZ_DELEGATE_CLASS="org.quartz.impl.jdbcjobstore.MSSQLDelegate" + quartzDriverDelegateSet="true" + DB_TYPE="SQLSERVER" + + if [ "x${QUARTZ_DATABASE}" != "x" ]; then + local databaseName="${QUARTZ_DATABASE}" + fi + + if [ "x${QUARTZ_XA_CONNECTION_PROPERTY_URL}" != "x" ]; then + local databaseName="${QUARTZ_XA_CONNECTION_PROPERTY_URL#*=}" + fi + + if [ "x${QUARTZ_URL}" != "x" ]; then + local databaseName="${QUARTZ_URL#*=}" + fi + + sed -i "s|USE \[enter_db_name_here\]|USE ${databaseName}|" $JBOSS_HOME/bin/quartz_tables_sqlserver.sql + + elif [[ "${KIE_SERVER_PERSISTENCE_DIALECT}" == "org.hibernate.dialect.DB2"* ]]; then + quartzDriverDelegateSet="true" + DB_TYPE="DB2" + fi + if [ "${quartzDriverDelegateSet}" = "true" ] && [ "${quartzManagedJndiSet=}" = "true" ] && [ "${quartzNotManagedJndiSet=}" = "true" ]; then - KIE_SERVER_OPTS="${KIE_SERVER_OPTS} -Dorg.quartz.properties=${quartzPropFile}" + sed -i "s,org.quartz.jobStore.driverDelegateClass=,org.quartz.jobStore.driverDelegateClass=${QUARTZ_DELEGATE_CLASS}," ${quartzPropFile} + sed -i "s,org.quartz.dataSource.managedDS.jndiURL=,org.quartz.dataSource.managedDS.jndiURL=${DEFAULT_JNDI}," ${quartzPropFile} + sed -i "s,org.quartz.dataSource.notManagedDS.jndiURL=,org.quartz.dataSource.notManagedDS.jndiURL=${QUARTZ_JNDI}," ${quartzPropFile} + KIE_SERVER_OPTS="${KIE_SERVER_OPTS} -Dorg.quartz.properties=${quartzPropFile} -Dorg.openshift.kieserver.common.sql.dbtype=${DB_TYPE}" fi fi } @@ -71,7 +127,10 @@ setupKieServerForOpenShift() { # filter the KIE Server kie-server-jms.xml and ejb-jar.xml files filterKieJmsFile "${JBOSS_HOME}/standalone/deployments/kie-server.war/META-INF/kie-server-jms.xml" filterKieJmsFile "${JBOSS_HOME}/standalone/deployments/kie-server.war/WEB-INF/ejb-jar.xml" - + + # setup the drivers, if exists + configure_drivers + # filter the KIE Server quartz.properties file filterQuartzPropFile "${JBOSS_HOME}/bin/quartz.properties" diff --git a/os.kieserver.launch/added/quartz.properties b/os.kieserver.launch/added/quartz.properties index 0c18800c..c2ec501f 100644 --- a/os.kieserver.launch/added/quartz.properties +++ b/os.kieserver.launch/added/quartz.properties @@ -1,39 +1,41 @@ # Configure Main Scheduler Properties #============================================================================ -org.quartz.scheduler.instanceName = jBPMClusteredScheduler -org.quartz.scheduler.instanceId = AUTO +org.quartz.scheduler.instanceName=jBPMClusteredScheduler +org.quartz.scheduler.instanceId=AUTO #============================================================================ # Configure ThreadPool #============================================================================ -org.quartz.threadPool.class = org.quartz.simpl.SimpleThreadPool -org.quartz.threadPool.threadCount = 5 -org.quartz.threadPool.threadPriority = 5 +org.quartz.threadPool.class=org.quartz.simpl.SimpleThreadPool +org.quartz.threadPool.threadCount=5 +org.quartz.threadPool.threadPriority=5 #============================================================================ # Configure JobStore #============================================================================ -org.quartz.jobStore.misfireThreshold = 60000 - +org.quartz.jobStore.misfireThreshold=60000 org.quartz.jobStore.class=org.quartz.impl.jdbcjobstore.JobStoreCMT -#The filed below will be configured by the kieserver-config.sh -#for mysql: org.quartz.impl.jdbcjobstore.StdJDBCDelegate -#for postgresql: org.quartz.impl.jdbcjobstore.PostgreSQLDelegate +# The property below will be configured by the kieserver-setup.sh +# for mysql: org.quartz.impl.jdbcjobstore.StdJDBCDelegate +# for postgresql: org.quartz.impl.jdbcjobstore.PostgreSQLDelegate +# for oracle: org.quartz.impl.jdbcjobstore.oracle.OracleDelegate +# for sqlserver: org.quartz.impl.jdbcjobstore.MSSQLDelegate +# for db2: org.quartz.impl.jdbcjobstore.StdJDBCDelegate org.quartz.jobStore.driverDelegateClass= org.quartz.jobStore.useProperties=false org.quartz.jobStore.dataSource=managedDS org.quartz.jobStore.nonManagedTXDataSource=notManagedDS org.quartz.jobStore.tablePrefix=QRTZ_ org.quartz.jobStore.isClustered=true -org.quartz.jobStore.clusterCheckinInterval = 20000 +org.quartz.jobStore.clusterCheckinInterval=20000 #============================================================================ # Configure Datasources #============================================================================ -#Needs to be added kieserver-config.sh script as we don't know the JNDIs +#Needs to be added by kieserver-setup.sh script as we don't know the JNDIs org.quartz.dataSource.managedDS.jndiURL= org.quartz.dataSource.notManagedDS.jndiURL= diff --git a/os.kieserver.launch/configure.sh b/os.kieserver.launch/configure.sh index ee9209cc..8f8fe111 100755 --- a/os.kieserver.launch/configure.sh +++ b/os.kieserver.launch/configure.sh @@ -18,8 +18,14 @@ if [ -e ${SOURCES_DIR}/jboss-bpmsuite-*-supplementary-tools.zip ]; then # Get the DDL files and copy to $JBOSS_HOME/bin/ unzip -qj ${SOURCES_DIR}/jboss-bpmsuite-*-supplementary-tools.zip jboss-brms-bpmsuite-*-supplementary-tools/ddl-scripts/mysql5/quartz_tables_mysql.sql -d ${SCRIPT_DIR} unzip -qj ${SOURCES_DIR}/jboss-bpmsuite-*-supplementary-tools.zip jboss-brms-bpmsuite-*-supplementary-tools/ddl-scripts/postgresql/quartz_tables_postgres.sql -d ${SCRIPT_DIR} + unzip -qj ${SOURCES_DIR}/jboss-bpmsuite-*-supplementary-tools.zip jboss-brms-bpmsuite-*-supplementary-tools/ddl-scripts/oracle/quartz_tables_oracle.sql -d ${SCRIPT_DIR} + unzip -qj ${SOURCES_DIR}/jboss-bpmsuite-*-supplementary-tools.zip jboss-brms-bpmsuite-*-supplementary-tools/ddl-scripts/sqlserver/quartz_tables_sqlserver.sql -d ${SCRIPT_DIR} + unzip -qj ${SOURCES_DIR}/jboss-bpmsuite-*-supplementary-tools.zip jboss-brms-bpmsuite-*-supplementary-tools/ddl-scripts/db2/quartz_tables_db2.sql -d ${SCRIPT_DIR} cp -p ${SCRIPT_DIR}/quartz_tables_mysql.sql ${JBOSS_HOME}/bin/ cp -p ${SCRIPT_DIR}/quartz_tables_postgres.sql ${JBOSS_HOME}/bin/ + cp -p ${SCRIPT_DIR}/quartz_tables_oracle.sql ${JBOSS_HOME}/bin/ + cp -p ${SCRIPT_DIR}/quartz_tables_sqlserver.sql ${JBOSS_HOME}/bin/ + cp -p ${SCRIPT_DIR}/quartz_tables_db2.sql ${JBOSS_HOME}/bin/ fi # Enforces eap70 password policy for the add-user script. diff --git a/os.kieserver.webapp/added/WEB-INF/jboss-deployment-structure-eap6x.xml b/os.kieserver.webapp/added/WEB-INF/jboss-deployment-structure-eap6x.xml index 035edf23..4341137d 100644 --- a/os.kieserver.webapp/added/WEB-INF/jboss-deployment-structure-eap6x.xml +++ b/os.kieserver.webapp/added/WEB-INF/jboss-deployment-structure-eap6x.xml @@ -28,6 +28,7 @@ + diff --git a/os.kieserver.webapp/added/WEB-INF/jboss-deployment-structure-eap7x.xml b/os.kieserver.webapp/added/WEB-INF/jboss-deployment-structure-eap7x.xml index bf45f56c..d30fb20c 100644 --- a/os.kieserver.webapp/added/WEB-INF/jboss-deployment-structure-eap7x.xml +++ b/os.kieserver.webapp/added/WEB-INF/jboss-deployment-structure-eap7x.xml @@ -26,6 +26,7 @@ the WAR depends on private modules. --> + \ No newline at end of file diff --git a/os.kieserver.webapp/configure.sh b/os.kieserver.webapp/configure.sh index 7ccec86e..970efe16 100755 --- a/os.kieserver.webapp/configure.sh +++ b/os.kieserver.webapp/configure.sh @@ -44,9 +44,11 @@ fi cp -f -p ${SOURCES_DIR}/openshift-kieserver-common-${OPENSHIFT_KIESERVER_VERSION}.jar ${KIE_SERVER_WEBINF_DIR}/lib/openshift-kieserver-common-${OPENSHIFT_KIESERVER_VERSION}.jar cp -f -p ${SOURCES_DIR}/openshift-kieserver-jms-${OPENSHIFT_KIESERVER_VERSION}.jar ${KIE_SERVER_WEBINF_DIR}/lib/openshift-kieserver-jms-${OPENSHIFT_KIESERVER_VERSION}.jar cp -f -p ${SOURCES_DIR}/openshift-kieserver-web-${OPENSHIFT_KIESERVER_VERSION}.jar ${KIE_SERVER_WEBINF_DIR}/lib/openshift-kieserver-web-${OPENSHIFT_KIESERVER_VERSION}.jar +cp -f -p ${SOURCES_DIR}/quartz-oracle-1.8.5.jar ${KIE_SERVER_WEBINF_DIR}/lib/ chmod 664 "${KIE_SERVER_WEBINF_DIR}/lib/openshift-kieserver-common-${OPENSHIFT_KIESERVER_VERSION}.jar" chmod 664 "${KIE_SERVER_WEBINF_DIR}/lib/openshift-kieserver-jms-${OPENSHIFT_KIESERVER_VERSION}.jar" chmod 664 "${KIE_SERVER_WEBINF_DIR}/lib/openshift-kieserver-web-${OPENSHIFT_KIESERVER_VERSION}.jar" +chmod 664 "${KIE_SERVER_WEBINF_DIR}/lib/quartz-oracle-1.8.5.jar" cp -f -p ${ADDED_WEBINF_DIR}/ejb-jar.xml ${KIE_SERVER_WEBINF_DIR}/ejb-jar.xml cp -f -p ${ADDED_WEBINF_DIR}/security-filter-rules.properties ${KIE_SERVER_WEBINF_DIR}/security-filter-rules.properties diff --git a/os.kieserver.webapp/module.yaml b/os.kieserver.webapp/module.yaml index 34de14ce..1beee144 100644 --- a/os.kieserver.webapp/module.yaml +++ b/os.kieserver.webapp/module.yaml @@ -4,4 +4,3 @@ version: '1.0' description: Legacy os.kieserver.webapp script package. execute: - script: configure.sh - user: '185' diff --git a/tests/features/processserver/processserver_6_4.feature b/tests/features/processserver/processserver_6_4.feature index 67eaa89f..44b453ca 100644 --- a/tests/features/processserver/processserver_6_4.feature +++ b/tests/features/processserver/processserver_6_4.feature @@ -1,6 +1,6 @@ -@jboss-processserver-6/processserver64-openshift +@jboss-processserver-6/processserver64-openshift @wip Feature: OpenShift Process Server 6.4 basic tests - + Scenario: Check for add-user failures When container is ready Then container log should contain Running jboss-processserver-6/processserver64-openshift image @@ -18,68 +18,321 @@ Feature: OpenShift Process Server 6.4 basic tests Scenario: Test REST API is secure When container is ready Then check that page is served - | property | value | - | port | 8080 | - | path | /kie-server/services/rest/server | - | expected_status_code | 401 | + | property | value | + | port | 8080 | + | path | /kie-server/services/rest/server | + | expected_status_code | 401 | - Scenario: Test REST API is available and valid + Scenario: Test REST API is available and valid When container is ready Then check that page is served - | property | value | - | port | 8080 | - | path | /kie-server/services/rest/server | - | username | kieserver | - | password | kieserver1! | - | expected_phrase | SUCCESS | - - Scenario: Checks SQL Importer behaviour if QUARTZ_JNDI variable does not exists + | property | value | + | port | 8080 | + | path | /kie-server/services/rest/server | + | username | kieserver | + | password | kieserver1! | + | expected_phrase | SUCCESS | + + Scenario: Checks SQL Importer behaviour if QUARTZ_JNDI variable does not exists When container is ready Then container log should contain QUARTZ_JNDI env not found, skipping SqlImporter Scenario: Checks if the Quartz was successfully configured with MySQL When container is started with env - | variable | value | - | DB_SERVICE_PREFIX_MAPPING | kie-app-mysql=DB,kie-app-mysql=QUARTZ | - | DB_DATABASE | mydb | - | DB_USERNAME | root | - | DB_PASSWORD | password | - | DB_JNDI | java:jboss/datasources/ExampleDS | - | QUARTZ_JNDI | java:jboss/datasources/ExampleDSNotManaged | - | QUARTZ_DATABASE | mydb | - | QUARTZ_USERNAME | root | - | QUARTZ_PASSWORD | password | - | QUARTZ_JTA | false | - | QUARTZ_NONXA | true | - | KIE_APP_MYSQL_SERVICE_HOST | 10.1.1.1 | - | KIE_APP_MYSQL_SERVICE_PORT | 3306 | + | variable | value | + | DB_SERVICE_PREFIX_MAPPING | kie-app-mysql=DB,kie-app-mysql=QUARTZ | + | DB_DATABASE | mydb | + | DB_USERNAME | root | + | DB_PASSWORD | password | + | DB_JNDI | java:jboss/datasources/ExampleDS | + | QUARTZ_JNDI | java:jboss/datasources/ExampleDSNotManaged | + | QUARTZ_DATABASE | mydb | + | QUARTZ_USERNAME | root | + | QUARTZ_PASSWORD | password | + | QUARTZ_JTA | false | + | QUARTZ_NONXA | true | + | KIE_APP_MYSQL_SERVICE_HOST | 10.1.1.1 | + | KIE_APP_MYSQL_SERVICE_PORT | 3306 | + | KIE_SERVER_PERSISTENCE_DIALECT | org.hibernate.dialect.MySQLDialect | + Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value mysql on XPath //*[local-name()='xa-datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value mysql on XPath //*[local-name()='datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDS on XPath //*[local-name()='xa-datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDSNotManaged on XPath //*[local-name()='datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/@jta + And container log should contain Starting SqlImporter... + + Scenario: Checks if the Quartz was successfully configured with MySQL with DATASOURCE env + When container is started with env + | variable | value | + | DATASOURCES | DB,QUARTZ | + | DB_DRIVER | mysql | + | DB_DATABASE | mydb | + | DB_USERNAME | root | + | DB_PASSWORD | password | + | DB_SERVICE_HOST | 10.1.1.1 | + | DB_SERVICE_PORT | 3306 | + | DB_JNDI | java:jboss/datasources/ExampleDS | + | QUARTZ_DRIVER | mysql | + | QUARTZ_JNDI | java:jboss/datasources/ExampleDSNotManaged | + | QUARTZ_DATABASE | mydb | + | QUARTZ_USERNAME | root | + | QUARTZ_PASSWORD | password | + | QUARTZ_JTA | false | + | QUARTZ_NONXA | true | + | QUARTZ_SERVICE_HOST | 10.1.1.1 | + | QUARTZ_SERVICE_PORT | 3306 | + | KIE_SERVER_PERSISTENCE_DIALECT | org.hibernate.dialect.MySQLDialect | Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value mysql on XPath //*[local-name()='xa-datasource']/*[local-name()='driver'] - Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value mysql on XPath //*[local-name()='datasource']/*[local-name()='driver'] - Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDS on XPath //*[local-name()='xa-datasource']/@jndi-name - Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDSNotManaged on XPath //*[local-name()='datasource']/@jndi-name - Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/@jta + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value mysql on XPath //*[local-name()='datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDS on XPath //*[local-name()='xa-datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDSNotManaged on XPath //*[local-name()='datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/@jta + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value org.jboss.jca.adapters.jdbc.extensions.mysql.MySQLValidConnectionChecker on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value org.jboss.jca.adapters.jdbc.extensions.mysql.MySQLExceptionSorter on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value org.jboss.jca.adapters.jdbc.extensions.mysql.MySQLValidConnectionChecker on XPath //*[local-name()='xa-datasource']//*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value org.jboss.jca.adapters.jdbc.extensions.mysql.MySQLExceptionSorter on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value mysql on XPath //*[local-name()='driver']/@name + And container log should contain Starting SqlImporter... Scenario: Checks if the Quartz was successfully configured with PostgreSQL When container is started with env - | variable | value | - | DB_SERVICE_PREFIX_MAPPING | kie-app-postgresql=DB,kie-app-postgresql=QUARTZ | - | DB_DATABASE | mydb | - | DB_USERNAME | root | - | DB_PASSWORD | password | - | DB_JNDI | java:jboss/datasources/ExampleDS | - | QUARTZ_JNDI | java:jboss/datasources/ExampleDSNotManaged | - | QUARTZ_DATABASE | mydb | - | QUARTZ_USERNAME | root | - | QUARTZ_PASSWORD | password | - | QUARTZ_JTA | false | - | QUARTZ_NONXA | true | - | KIE_APP_POSTGRESQL_SERVICE_HOST | 10.1.1.1 | - | KIE_APP_POSTGRESQL_SERVICE_PORT | 5432 | + | variable | value | + | DB_SERVICE_PREFIX_MAPPING | kie-app-postgresql=DB,kie-app-postgresql=QUARTZ | + | DB_DATABASE | mydb | + | DB_USERNAME | root | + | DB_PASSWORD | password | + | DB_JNDI | java:jboss/datasources/ExampleDS | + | QUARTZ_JNDI | java:jboss/datasources/ExampleDSNotManaged | + | QUARTZ_DATABASE | mydb | + | QUARTZ_USERNAME | root | + | QUARTZ_PASSWORD | password | + | QUARTZ_JTA | false | + | QUARTZ_NONXA | true | + | KIE_APP_POSTGRESQL_SERVICE_HOST | 10.1.1.1 | + | KIE_APP_POSTGRESQL_SERVICE_PORT | 5432 | + | KIE_SERVER_PERSISTENCE_DIALECT | org.hibernate.dialect.MySQL82Dialect | + Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value postgresql on XPath //*[local-name()='xa-datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value postgresql on XPath //*[local-name()='datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDS on XPath //*[local-name()='xa-datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDSNotManaged on XPath //*[local-name()='datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/@jta + And container log should contain Starting SqlImporter... + + Scenario: Checks if the Quartz was successfully configured with PostgreSQL env DATASOURCE env + When container is started with env + | variable | value | + | DATASOURCES | DB,QUARTZ | + | DB_DRIVER | postgresql | + | DB_DATABASE | mydb | + | DB_USERNAME | root | + | DB_PASSWORD | password | + | DB_SERVICE_HOST | 10.1.1.1 | + | DB_SERVICE_PORT | 5432 | + | DB_JNDI | java:jboss/datasources/ExampleDS | + | QUARTZ_DRIVER | postgresql | + | QUARTZ_JNDI | java:jboss/datasources/ExampleDSNotManaged | + | QUARTZ_DATABASE | mydb | + | QUARTZ_USERNAME | root | + | QUARTZ_PASSWORD | password | + | QUARTZ_JTA | false | + | QUARTZ_NONXA | true | + | QUARTZ_SERVICE_HOST | 10.1.1.1 | + | QUARTZ_SERVICE_PORT | 5432 | + | KIE_SERVER_PERSISTENCE_DIALECT | org.hibernate.dialect.MySQL82Dialect | Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value postgresql on XPath //*[local-name()='xa-datasource']/*[local-name()='driver'] - And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value postgresql on XPath //*[local-name()='datasource']/*[local-name()='driver'] - And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDS on XPath //*[local-name()='xa-datasource']/@jndi-name - And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDSNotManaged on XPath //*[local-name()='datasource']/@jndi-name - And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/@jta + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value postgresql on XPath //*[local-name()='datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDS on XPath //*[local-name()='xa-datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/ExampleDSNotManaged on XPath //*[local-name()='datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/@jta + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value org.jboss.jca.adapters.jdbc.extensions.postgres.PostgreSQLValidConnectionChecker on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value org.jboss.jca.adapters.jdbc.extensions.postgres.PostgreSQLExceptionSorter on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value org.jboss.jca.adapters.jdbc.extensions.postgres.PostgreSQLValidConnectionChecker on XPath //*[local-name()='xa-datasource']//*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value org.jboss.jca.adapters.jdbc.extensions.postgres.PostgreSQLExceptionSorter on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value mysql on XPath //*[local-name()='driver']/@name + And container log should contain Starting SqlImporter... + + Scenario: Checks if the Quartz was successfully configured with Oracle db + When container is started with env + | variable | value | + | DATASOURCES | DB,QUARTZ | + | DB_JNDI | java:jboss/datasources/jbpmDS | + | DB_XA_CONNECTION_PROPERTY_URL | jdbc:oracle:thin:@10.1.1.1:1521:jbpm | + | DB_USERNAME | root | + | DB_PASSWORD | password | + | DB_NONXA | false | + | DB_DRIVER | oracle | + | DB_CONNECTION_CHECKER | OracleValidConnectionChecker | + | DB_EXCEPTION_SORTER | OracleExceptionSorter | + | DB_BACKGROUND_VALIDATION | true | + | QUARTZ_JNDI | java:jboss/datasources/jbpmDSNotManaged | + | QUARTZ_URL | jdbc:oracle:thin:@10.1.1.1:1521:jbpm | + | QUARTZ_DATABASE | mydb | + | QUARTZ_USERNAME | root | + | QUARTZ_PASSWORD | password | + | QUARTZ_JTA | false | + | QUARTZ_NONXA | true | + | QUARTZ_DRIVER | oracle | + | QUARTZ_DRIVER_MODULE | com.oracle | + | QUARTZ_CONNECTION_CHECKER | OracleValidConnectionChecker | + | QUARTZ_EXCEPTION_SORTER | OracleExceptionSorter | + | QUARTZ_BACKGROUND_VALIDATION | true | + | KIE_SERVER_PERSISTENCE_DIALECT | org.hibernate.dialect.Oracle10gDialect | + Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value oracle on XPath //*[local-name()='xa-datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value oracle on XPath //*[local-name()='datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value jdbc:oracle:thin:@10.1.1.1:1521:jbpm on XPath //*[local-name()='datasource']/*[local-name()='connection-url'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value jdbc:oracle:thin:@10.1.1.1:1521:jbpm on XPath //*[local-name()='xa-datasource']/*[local-name()='xa-datasource-property'][@name="URL"] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/jbpmDS on XPath //*[local-name()='xa-datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/jbpmDSNotManaged on XPath //*[local-name()='datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/@jta + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value OracleValidConnectionChecker on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value OracleExceptionSorter on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value 10000 on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='background-validation-millis'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value OracleValidConnectionChecker on XPath //*[local-name()='xa-datasource']//*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value OracleExceptionSorter on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value 10000 on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='background-validation-millis'] + And file /opt/eap/standalone/deployments/kie-server.war/WEB-INF/jboss-deployment-structure.xml should contain + + Scenario: Checks if the Quartz was successfully configured with oracle d + When container is started with env + | variable | value | + | DATASOURCES | DB,QUARTZ | + | DB_JNDI | java:jboss/datasources/jbpmDS | + | DB_XA_CONNECTION_PROPERTY_URL | jdbc:oracle:thin:@10.1.1.1:1521:jbpm | + | DB_USERNAME | root | + | DB_PASSWORD | password | + | DB_DRIVER | oracle | + | DB_CONNECTION_CHECKER | OracleValidConnectionChecker | + | DB_EXCEPTION_SORTER | OracleExceptionSorter | + | DB_BACKGROUND_VALIDATION | true | + | QUARTZ_JNDI | java:jboss/datasources/jbpmDSNotManaged | + | QUARTZ_URL | jdbc:oracle:thin:@10.1.1.1:1521:jbpm | + | QUARTZ_DATABASE | mydb | + | QUARTZ_USERNAME | root | + | QUARTZ_PASSWORD | password | + | QUARTZ_JTA | false | + | QUARTZ_NONXA | true | + | QUARTZ_DRIVER | oracle | + | QUARTZ_DRIVER_MODULE | deployment.ojdbc6.jar | + | QUARTZ_CONNECTION_CHECKER | OracleValidConnectionChecker | + | QUARTZ_EXCEPTION_SORTER | OracleExceptionSorter | + | QUARTZ_BACKGROUND_VALIDATION | true | + | KIE_SERVER_PERSISTENCE_DIALECT | org.hibernate.dialect.Oracle10gDialect | + Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value oracle on XPath //*[local-name()='xa-datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value oracle on XPath //*[local-name()='datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value jdbc:oracle:thin:@10.1.1.1:1521:jbpm on XPath //*[local-name()='datasource']/*[local-name()='connection-url'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value jdbc:oracle:thin:@10.1.1.1:1521:jbpm on XPath //*[local-name()='xa-datasource']/*[local-name()='xa-datasource-property'][@name="URL"] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/jbpmDS on XPath //*[local-name()='xa-datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/jbpmDSNotManaged on XPath //*[local-name()='datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/@jta + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value OracleValidConnectionChecker on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value OracleExceptionSorter on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value 10000 on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='background-validation-millis'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value OracleValidConnectionChecker on XPath //*[local-name()='xa-datasource']//*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value OracleExceptionSorter on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value 10000 on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='background-validation-millis'] + And file /opt/eap/standalone/deployments/kie-server.war/WEB-INF/jboss-deployment-structure.xml should contain + + Scenario: Checks if the Quartz was successfully configured with db2 with no schema + When container is started with env + | variable | value | + | DATASOURCES | DB,QUARTZ | + | DB_JNDI | java:jboss/datasources/jbpmDS | + | DB_XA_CONNECTION_PROPERTY_URL | jdbc:db2://myhost:5021/jbpm | + | DB_USERNAME | root | + | DB_PASSWORD | password | + | DB_DRIVER | db2 | + | DB_CONNECTION_CHECKER | DB2ValidConnectionChecker | + | DB_EXCEPTION_SORTER | DB2ExceptionSorter | + | DB_BACKGROUND_VALIDATION | true | + | QUARTZ_JNDI | java:jboss/datasources/jbpmDSNotManaged | + | QUARTZ_URL | jdbc:db2://myhost:5021/jbpm | + | QUARTZ_DATABASE | mydb | + | QUARTZ_USERNAME | root | + | QUARTZ_PASSWORD | password | + | QUARTZ_JTA | false | + | QUARTZ_NONXA | true | + | QUARTZ_DRIVER | db2 | + | QUARTZ_CONNECTION_CHECKER | DB2ValidConnectionChecker | + | QUARTZ_EXCEPTION_SORTER | DB2ExceptionSorter | + | QUARTZ_BACKGROUND_VALIDATION | true | + | KIE_SERVER_PERSISTENCE_DIALECT | org.hibernate.dialect.DB2Dialect | + Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value db2 on XPath //*[local-name()='xa-datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value db2 on XPath //*[local-name()='datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value jdbc:db2://myhost:5021/jbpm on XPath //*[local-name()='datasource']/*[local-name()='connection-url'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value jdbc:db2://myhost:5021/jbpm on XPath //*[local-name()='xa-datasource']/*[local-name()='xa-datasource-property'][@name="URL"] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/jbpmDS on XPath //*[local-name()='xa-datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/jbpmDSNotManaged on XPath //*[local-name()='datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/@jta + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value DB2ValidConnectionChecker on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value DB2ExceptionSorter on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value 10000 on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='background-validation-millis'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value DB2ValidConnectionChecker on XPath //*[local-name()='xa-datasource']//*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value DB2ExceptionSorter on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value 10000 on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='background-validation-millis'] + + Scenario: Checks if the Quartz was successfully configured with db2 + When container is started with env + | variable | value | + | DATASOURCES | DB,QUARTZ | + | DB_JNDI | java:jboss/datasources/jbpmDS | + | DB_XA_CONNECTION_PROPERTY_URL | jdbc:db2://myhost:5021/jbpm | + | DB_USERNAME | root | + | DB_PASSWORD | password | + | DB_DRIVER | db2 | + | DB_CONNECTION_CHECKER | DB2ValidConnectionChecker | + | DB_EXCEPTION_SORTER | DB2ExceptionSorter | + | DB_BACKGROUND_VALIDATION | true | + | QUARTZ_JNDI | java:jboss/datasources/jbpmDSNotManaged | + | QUARTZ_URL | jdbc:db2://myhost:5021/jbpm | + | QUARTZ_DATABASE | mydb | + | QUARTZ_USERNAME | root | + | QUARTZ_PASSWORD | password | + | QUARTZ_JTA | false | + | QUARTZ_NONXA | true | + | QUARTZ_DRIVER | db2 | + | QUARTZ_CONNECTION_CHECKER | DB2ValidConnectionChecker | + | QUARTZ_EXCEPTION_SORTER | DB2ExceptionSorter | + | QUARTZ_BACKGROUND_VALIDATION | true | + | KIE_SERVER_PERSISTENCE_DIALECT | org.hibernate.dialect.DB2Dialect | + | KIE_SERVER_PERSISTENCE_SCHEMA | my.schema | + Then XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value db2 on XPath //*[local-name()='xa-datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value db2 on XPath //*[local-name()='datasource']/*[local-name()='driver'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value jdbc:db2://myhost:5021/jbpm on XPath //*[local-name()='datasource']/*[local-name()='connection-url'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value jdbc:db2://myhost:5021/jbpm on XPath //*[local-name()='xa-datasource']/*[local-name()='xa-datasource-property'][@name="URL"] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/jbpmDS on XPath //*[local-name()='xa-datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value java:jboss/datasources/jbpmDSNotManaged on XPath //*[local-name()='datasource']/@jndi-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/@jta + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value DB2ValidConnectionChecker on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value DB2ExceptionSorter on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value 10000 on XPath //*[local-name()='datasource']/*[local-name()='validation']/*[local-name()='background-validation-millis'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value DB2ValidConnectionChecker on XPath //*[local-name()='xa-datasource']//*[local-name()='validation']/*[local-name()='valid-connection-checker']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value DB2ExceptionSorter on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='exception-sorter']/@class-name + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value false on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='validate-on-match'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value true on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='background-validation'] + And XML file /opt/eap/standalone/configuration/standalone-openshift.xml should contain value 10000 on XPath //*[local-name()='xa-datasource']/*[local-name()='validation']/*[local-name()='background-validation-millis'] + And container log should contain -Dorg.kie.server.persistence.schema=my.schema Scenario: check ownership when started as alternative UID When container is started as uid 26458 @@ -91,7 +344,7 @@ Feature: OpenShift Process Server 6.4 basic tests Scenario: Checks that CLOUD-1476 patch upgrade was successful When container is ready Then file /opt/eap/standalone/deployments/kie-server.war/WEB-INF/web.xml should contain org.openshift.kieserver - And file /opt/eap/standalone/deployments/kie-server.war/WEB-INF/security-filter-rules.properties should exist - And file /opt/eap/standalone/deployments/kie-server.war/WEB-INF/lib/kie-api-6.5.0.Final-redhat-2.jar should not exist - And file /opt/eap/standalone/deployments/kie-server.war/WEB-INF/lib/kie-api-6.5.0.Final-redhat-21.jar should exist - And file /opt/eap/standalone/deployments/kie-server.war/WEB-INF/lib/openshift-kieserver-common-1.2.0.Final-redhat-1.jar should exist + And file /opt/eap/standalone/deployments/kie-server.war/WEB-INF/security-filter-rules.properties should exist + And file /opt/eap/standalone/deployments/kie-server.war/WEB-INF/lib/kie-api-6.5.0.Final-redhat-2.jar should not exist + And file /opt/eap/standalone/deployments/kie-server.war/WEB-INF/lib/kie-api-6.5.0.Final-redhat-21.jar should exist + And file /opt/eap/standalone/deployments/kie-server.war/WEB-INF/lib/openshift-kieserver-common-1.2.2.Final-redhat-1.jar should exist diff --git a/tests/features/processserver/processserver_s2i.feature b/tests/features/processserver/processserver_s2i.feature index 3a4c9ce6..d82776a1 100644 --- a/tests/features/processserver/processserver_s2i.feature +++ b/tests/features/processserver/processserver_s2i.feature @@ -3,9 +3,9 @@ Feature: Openshift Process Server s2i tests Scenario: deploys the library example, then checks if it's deployed. Given s2i build https://github.com/jboss-openshift/openshift-quickstarts from processserver/library using 1.3 - | variable | value | - | KIE_CONTAINER_DEPLOYMENT | LibraryContainer=org.openshift.quickstarts:processserver-library:1.4.0.Final | - | KIE_CONTAINER_REDIRECT_ENABLED | false | + | variable | value | + | KIE_CONTAINER_DEPLOYMENT | LibraryContainer=org.openshift.quickstarts:processserver-library:1.4.0.Final | + | KIE_CONTAINER_REDIRECT_ENABLED | false | Then container log should contain Container LibraryContainer # Always force IPv4 (CLOUD-188) @@ -13,32 +13,32 @@ Feature: Openshift Process Server s2i tests # Allow the user to clear down the maven repository after running s2i (CLOUD-413) Scenario: Test to ensure that maven is run with -Djava.net.preferIPv4Stack=true and user-supplied arguments, even when MAVEN_ARGS is overridden, and maven repo is ALWAYS left alone Given s2i build https://github.com/jboss-openshift/openshift-quickstarts from processserver/library using 1.3 - | variable | value | - | MAVEN_ARGS | -e -P jboss-eap-repository-insecure,-securecentral,insecurecentral -DskipTests package | - | MAVEN_ARGS_APPEND | -Dfoo=bar | - | MAVEN_CLEAR_REPO | true | - Then s2i build log should contain -Djava.net.preferIPv4Stack=true - Then s2i build log should contain -Dfoo=bar - Then s2i build log should contain -XX:+UnlockExperimentalVMOptions -XX:+UseCGroupMemoryLimitForHeap -XX:+UseParallelOldGC -XX:MinHeapFreeRatio=10 -XX:MaxHeapFreeRatio=20 -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -XX:MaxMetaspaceSize=100m -XX:+ExitOnOutOfMemoryError - Then run sh -c 'test -d /home/jboss/.m2/repository/org && echo all good' in container and check its output for all good + | variable | value | + | MAVEN_ARGS | -e -P jboss-eap-repository-insecure,-securecentral,insecurecentral -DskipTests package | + | MAVEN_ARGS_APPEND | -Dfoo=bar | + | MAVEN_CLEAR_REPO | true | + Then s2i build log should contain -Djava.net.preferIPv4Stack=true + Then s2i build log should contain -Dfoo=bar + Then s2i build log should contain -XX:+UnlockExperimentalVMOptions -XX:+UseCGroupMemoryLimitForHeap -XX:+UseParallelOldGC -XX:MinHeapFreeRatio=10 -XX:MaxHeapFreeRatio=20 -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -XX:MaxMetaspaceSize=100m + Then run sh -c 'test -d /home/jboss/.m2/repository/org && echo all good' in container and check its output for all good # CLOUD-579 Scenario: Test that maven is executed in batch mode - Given s2i build https://github.com/jboss-openshift/openshift-quickstarts from processserver/library using 1.3 + Given s2i build https://github.com/jboss-openshift/openshift-quickstarts from processserver/library using 1.3 Then s2i build log should contain --batch-mode And s2i build log should not contain \r # CLOUD-1145 - base test Scenario: Check custom war file was successfully deployed via CUSTOM_INSTALL_DIRECTORIES Given s2i build https://github.com/jboss-openshift/openshift-examples.git from custom-install-directories - | variable | value | + | variable | value | | CUSTOM_INSTALL_DIRECTORIES | custom | Then file /opt/eap/standalone/deployments/node-info.war should exist # CLOUD-1145 - CSV test Scenario: Check all modules are successfully deployed using comma-separated CUSTOM_INSTALL_DIRECTORIES value Given s2i build https://github.com/jboss-openshift/openshift-examples.git from custom-install-directories - | variable | value | + | variable | value | | CUSTOM_INSTALL_DIRECTORIES | foo,bar | Then file /opt/eap/standalone/deployments/foo.jar should exist Then file /opt/eap/standalone/deployments/bar.jar should exist