diff --git a/.ci/openshift-ci/build-root/e2e-test-periodic.sh b/.ci/openshift-ci/build-root/e2e-test-periodic.sh index b9f9bcf2..df79f2f4 100644 --- a/.ci/openshift-ci/build-root/e2e-test-periodic.sh +++ b/.ci/openshift-ci/build-root/e2e-test-periodic.sh @@ -124,7 +124,7 @@ mvn test -Dmaven.repo.local=./local-repo-prod -pl testsuite/integration-tests -P -Dintersmash.rhsso.operators.catalog_source=redhat-operators \ -Dintersmash.rhsso.operators.package_manifest=rhsso-operator \ -Dintersmash.rhsso.templates=https://raw.githubusercontent.com/jboss-container-images/redhat-sso-7-openshift-image/sso76-dev/templates/ \ - -Dintersmash.infinispan.image=registry.redhat.io/jboss-datagrid-7/datagrid73-openshift:latest \ + -Dintersmash.infinispan.image=registry.redhat.io/datagrid/datagrid-8-rhel8:latest \ -Dintersmash.infinispan.operators.catalog_source=redhat-operators \ -Dintersmash.infinispan.operators.package_manifest=datagrid \ -Dintersmash.infinispan.operators.channel=8.4.x \ diff --git a/.ci/openshift-ci/build-root/e2e-test-prod.sh b/.ci/openshift-ci/build-root/e2e-test-prod.sh index 7e4a763a..139bebb9 100644 --- a/.ci/openshift-ci/build-root/e2e-test-prod.sh +++ b/.ci/openshift-ci/build-root/e2e-test-prod.sh @@ -135,7 +135,7 @@ mvn test -Dmaven.repo.local=./local-repo-prod -pl testsuite/integration-tests -P -Dintersmash.rhsso.operators.catalog_source=redhat-operators \ -Dintersmash.rhsso.operators.package_manifest=rhsso-operator \ -Dintersmash.rhsso.templates=https://raw.githubusercontent.com/jboss-container-images/redhat-sso-7-openshift-image/sso76-dev/templates/ \ - -Dintersmash.infinispan.image=registry.redhat.io/jboss-datagrid-7/datagrid73-openshift:latest \ + -Dintersmash.infinispan.image=registry.redhat.io/datagrid/datagrid-8-rhel8:latest \ -Dintersmash.infinispan.operators.catalog_source=redhat-operators \ -Dintersmash.infinispan.operators.package_manifest=datagrid \ -Dintersmash.infinispan.operators.channel=8.4.x \ diff --git a/README.md b/README.md index 755196df..0a4f62ba 100644 --- a/README.md +++ b/README.md @@ -219,7 +219,7 @@ Feel free to submit an issue in such a case, Intersmash welcomes community contr | ActiveMQ Artemis | 1.0.15 | The one provided by the custom index image, i.e. quay.io/jbossqe-eap/intersmash-activemq-operator-catalog:v1.0.11 | | Red Hat AMQ Broker | 7.11.z | Or _latest_ in the `:7.11` tag image stream, see registry.redhat.io/amq7/amq-broker-init-rhel8 | |||| -| Infinispan | 14.0.27.Final | Or _default_ provided by the default Infinispan Operator `2.4.x` channel | +| Infinispan | 15.0.3.Final | Or _default_ provided by the default Infinispan Operator `stable` channel | | Red Hat DataGrid | 8.4.8.GA | Or _default_ provided by the Red Hat DataGrid Operator `8.4.x` channel | | |||| | Kafka provided by Strimzi | 3.6.0 | Provided by the Strimzi Operator `stable` channel | diff --git a/provisioners/src/main/java/org/jboss/intersmash/provision/openshift/InfinispanOperatorProvisioner.java b/provisioners/src/main/java/org/jboss/intersmash/provision/openshift/InfinispanOperatorProvisioner.java index 8097e02c..e905ffca 100644 --- a/provisioners/src/main/java/org/jboss/intersmash/provision/openshift/InfinispanOperatorProvisioner.java +++ b/provisioners/src/main/java/org/jboss/intersmash/provision/openshift/InfinispanOperatorProvisioner.java @@ -110,9 +110,10 @@ public void scale(int replicas, boolean wait) { if (wait) { // waits for the correct number of Pods representing the Infinispan CR replicas to be ready new SimpleWaiter(() -> getInfinispanPods().size() == replicas).level(Level.DEBUG).waitFor(); + if (replicas > 0) { + waitForResourceReadiness(); + } } - // wait for all resources to be ready - waitForResourceReadiness(); } @Override diff --git a/testsuite/integration-tests/src/test/java/org/jboss/intersmash/testsuite/provision/openshift/OpenShiftProvisionerTestBase.java b/testsuite/integration-tests/src/test/java/org/jboss/intersmash/testsuite/provision/openshift/OpenShiftProvisionerTestBase.java index a0c8128a..d3685f07 100644 --- a/testsuite/integration-tests/src/test/java/org/jboss/intersmash/testsuite/provision/openshift/OpenShiftProvisionerTestBase.java +++ b/testsuite/integration-tests/src/test/java/org/jboss/intersmash/testsuite/provision/openshift/OpenShiftProvisionerTestBase.java @@ -28,11 +28,14 @@ import java.util.Map; import org.assertj.core.util.Strings; +import org.infinispan.v1.Infinispan; +import org.infinispan.v2alpha1.Cache; import org.jboss.intersmash.IntersmashConfig; import org.jboss.intersmash.application.openshift.BootableJarOpenShiftApplication; import org.jboss.intersmash.application.openshift.Eap7ImageOpenShiftApplication; import org.jboss.intersmash.application.openshift.Eap7LegacyS2iBuildTemplateApplication; import org.jboss.intersmash.application.openshift.Eap7TemplateOpenShiftApplication; +import org.jboss.intersmash.application.openshift.InfinispanOperatorApplication; import org.jboss.intersmash.application.openshift.KafkaOperatorApplication; import org.jboss.intersmash.application.openshift.KeycloakOperatorApplication; import org.jboss.intersmash.application.openshift.MysqlImageOpenShiftApplication; @@ -46,6 +49,7 @@ import org.jboss.intersmash.application.openshift.template.Eap7Template; import org.jboss.intersmash.application.openshift.template.PostgreSQLTemplate; import org.jboss.intersmash.application.openshift.template.RhSsoTemplate; +import org.jboss.intersmash.provision.openshift.operator.infinispan.infinispan.InfinispanBuilder; import org.jboss.intersmash.test.deployments.DeploymentsProvider; import org.jboss.intersmash.test.deployments.TestDeploymentProperties; import org.jboss.intersmash.test.deployments.WildflyDeploymentApplicationConfiguration; @@ -759,4 +763,27 @@ public String getName() { } }; } + + static InfinispanOperatorApplication getInfinispanOperatorApplication() { + return new InfinispanOperatorApplication() { + private static final String DEFAULT_INFINISPAN_APP_NAME = "example-infinispan"; + + @Override + public Infinispan getInfinispan() { + return new InfinispanBuilder(DEFAULT_INFINISPAN_APP_NAME, Map.of("app", DEFAULT_INFINISPAN_APP_NAME)) + .replicas(1) + .build(); + } + + @Override + public List getCaches() { + return Collections.emptyList(); + } + + @Override + public String getName() { + return DEFAULT_INFINISPAN_APP_NAME; + } + }; + } } diff --git a/testsuite/integration-tests/src/test/java/org/jboss/intersmash/testsuite/provision/openshift/ProvisionerCleanupTestCase.java b/testsuite/integration-tests/src/test/java/org/jboss/intersmash/testsuite/provision/openshift/ProvisionerCleanupTestCase.java index 4d7d9109..9931f610 100644 --- a/testsuite/integration-tests/src/test/java/org/jboss/intersmash/testsuite/provision/openshift/ProvisionerCleanupTestCase.java +++ b/testsuite/integration-tests/src/test/java/org/jboss/intersmash/testsuite/provision/openshift/ProvisionerCleanupTestCase.java @@ -20,6 +20,7 @@ import org.jboss.intersmash.provision.openshift.Eap7ImageOpenShiftProvisioner; import org.jboss.intersmash.provision.openshift.Eap7LegacyS2iBuildTemplateProvisioner; +import org.jboss.intersmash.provision.openshift.InfinispanOperatorProvisioner; import org.jboss.intersmash.provision.openshift.KeycloakOperatorProvisioner; import org.jboss.intersmash.provision.openshift.MysqlImageOpenShiftProvisioner; import org.jboss.intersmash.provision.openshift.OpenShiftProvisioner; @@ -51,29 +52,37 @@ public class ProvisionerCleanupTestCase { private static Stream provisionerProvider() { if (IntersmashTestsuiteProperties.isCommunityTestExecutionProfileEnabled()) { return Stream.of( + // WildFly new WildflyBootableJarImageOpenShiftProvisioner( OpenShiftProvisionerTestBase.getWildflyBootableJarOpenShiftApplication()), new WildflyBootableJarImageOpenShiftProvisioner( - OpenShiftProvisionerTestBase.getEap7BootableJarOpenShiftApplication()), - new MysqlImageOpenShiftProvisioner(OpenShiftProvisionerTestBase.getMysqlOpenShiftApplication()), - new PostgreSQLImageOpenShiftProvisioner( + OpenShiftProvisionerTestBase.getEap7BootableJarOpenShiftApplication()) + // Keycloak + , new KeycloakOperatorProvisioner( + OpenShiftProvisionerTestBase.getKeycloakOperatorApplication()) + // Infinispan + , new InfinispanOperatorProvisioner(OpenShiftProvisionerTestBase.getInfinispanOperatorApplication()) + // MySQL + , new MysqlImageOpenShiftProvisioner(OpenShiftProvisionerTestBase.getMysqlOpenShiftApplication()) + // PostgreSql + , new PostgreSQLImageOpenShiftProvisioner( OpenShiftProvisionerTestBase.getPostgreSQLImageOpenShiftApplication()), new PostgreSQLTemplateOpenShiftProvisioner( - OpenShiftProvisionerTestBase.getPostgreSQLTemplateOpenShiftApplication()), - new KeycloakOperatorProvisioner( - OpenShiftProvisionerTestBase.getKeycloakOperatorApplication())); + OpenShiftProvisionerTestBase.getPostgreSQLTemplateOpenShiftApplication())); } else if (IntersmashTestsuiteProperties.isProductizedTestExecutionProfileEnabled()) { return Stream.of( // EAP latest GA new WildflyImageOpenShiftProvisioner( - OpenShiftProvisionerTestBase.getWildflyOpenShiftLocalBinaryTargetServerApplication()), + OpenShiftProvisionerTestBase.getWildflyOpenShiftLocalBinaryTargetServerApplication()) // EAP 7 - new Eap7ImageOpenShiftProvisioner(OpenShiftProvisionerTestBase.getEap7OpenShiftImageApplication()), + , new Eap7ImageOpenShiftProvisioner(OpenShiftProvisionerTestBase.getEap7OpenShiftImageApplication()) // RHSSO 7.6.x - new RhSsoTemplateOpenShiftProvisioner(OpenShiftProvisionerTestBase.getHttpsRhSso()), + , new RhSsoTemplateOpenShiftProvisioner(OpenShiftProvisionerTestBase.getHttpsRhSso()) // RHBK - new KeycloakOperatorProvisioner( - OpenShiftProvisionerTestBase.getKeycloakOperatorApplication())); + , new KeycloakOperatorProvisioner( + OpenShiftProvisionerTestBase.getKeycloakOperatorApplication()) + // RHDG + , new InfinispanOperatorProvisioner(OpenShiftProvisionerTestBase.getInfinispanOperatorApplication())); } else { throw new IllegalStateException( String.format("Unknown Intersmash test suite execution profile: %s",