This is an automated email from the ASF dual-hosted git repository. mmerli pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/incubator-pulsar.git
The following commit(s) were added to refs/heads/master by this push: new a28c2cf Arquillian topologies for integration testing (#1333) a28c2cf is described below commit a28c2cfcdd8d167064b09812c2773d617c427e48 Author: Ivan Kelly <iv...@apache.org> AuthorDate: Tue Mar 6 17:00:52 2018 +0100 Arquillian topologies for integration testing (#1333) Module to distribute arquillian topologies for integration testing. I've put them in a module so multiple tests can share the same topology. There is currently only one topology. This runs a single pulsar cluster with: - 1 local zookeeper container - 1 global zookeeper container - 3 bookkeeper bookie containers - 2 pulsar brokers (unstarted) - 1 pulsar proxy (unstarted) --- tests/{ => integration-tests-topologies}/pom.xml | 35 ++-- ...single-cluster-3-bookie-2-broker-unstarted.yaml | 182 +++++++++++++++++++++ tests/pom.xml | 1 + 3 files changed, 196 insertions(+), 22 deletions(-) diff --git a/tests/pom.xml b/tests/integration-tests-topologies/pom.xml similarity index 57% copy from tests/pom.xml copy to tests/integration-tests-topologies/pom.xml index 5c8429d..260681e 100644 --- a/tests/pom.xml +++ b/tests/integration-tests-topologies/pom.xml @@ -19,31 +19,22 @@ under the License. --> -<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> - <packaging>pom</packaging> +<project xmlns="http://maven.apache.org/POM/4.0.0" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation=" + http://maven.apache.org/POM/4.0.0 + http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> - <groupId>org.apache.pulsar</groupId> - <artifactId>pulsar</artifactId> + <groupId>org.apache.pulsar.tests</groupId> + <artifactId>tests-parent</artifactId> <version>2.0.0-incubating-SNAPSHOT</version> </parent> + <groupId>org.apache.pulsar.tests</groupId> - <artifactId>tests-parent</artifactId> - <name>Apache Pulsar :: Tests</name> - <modules> - <module>docker-images</module> - <module>integration-tests-utils</module> - </modules> - <build> - <plugins> - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-deploy-plugin</artifactId> - <configuration> - <skip>true</skip> - </configuration> - </plugin> - </plugins> - </build> + <artifactId>integration-tests-topologies</artifactId> + <packaging>jar</packaging> + + <name>Apache Pulsar :: Tests :: Common topologies for Arquillian based integration tests</name> + </project> diff --git a/tests/integration-tests-topologies/src/main/resources/cube-definitions/single-cluster-3-bookie-2-broker-unstarted.yaml b/tests/integration-tests-topologies/src/main/resources/cube-definitions/single-cluster-3-bookie-2-broker-unstarted.yaml new file mode 100644 index 0000000..a77d34d --- /dev/null +++ b/tests/integration-tests-topologies/src/main/resources/cube-definitions/single-cluster-3-bookie-2-broker-unstarted.yaml @@ -0,0 +1,182 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +# + +networks: + pulsarnet*: + driver: bridge + +zookeeper*: + image: apachepulsar/pulsar-test-latest-version:latest + await: + strategy: org.apache.pulsar.tests.NoopAwaitStrategy + env: [ZOOKEEPER_SERVERS=zookeeper] + labels: + cluster: test + service: zookeeper + entryPoint: [bin/run-local-zk.sh] + aliases: + - zookeeper + beforeStop: + - customBeforeStopAction: + strategy: org.apache.pulsar.tests.PulsarLogsToTargetDirStopAction + networkMode: pulsarnet* + +global-zookeeper*: + image: apachepulsar/pulsar-test-latest-version:latest + await: + strategy: org.apache.pulsar.tests.NoopAwaitStrategy + env: [ZOOKEEPER_SERVERS=zookeeper] + labels: + cluster: test + service: global-zookeeper + entryPoint: [bin/run-global-zk.sh] + aliases: + - global-zookeeper + beforeStop: + - customBeforeStopAction: + strategy: org.apache.pulsar.tests.PulsarLogsToTargetDirStopAction + networkMode: pulsarnet* + +init*: + image: apachepulsar/pulsar-test-latest-version:latest + await: + strategy: org.apache.pulsar.tests.NoopAwaitStrategy + env: + - cluster=test + - zkServers=zookeeper + - globalZkServers=global-zookeeper:2184 + - pulsarNode=pulsar-broker1 + labels: + cluster: test + service: init + entryPoint: [bin/init-cluster.sh] + beforeStop: + - customBeforeStopAction: + strategy: org.apache.pulsar.tests.LogToTargetDirStopAction + networkMode: pulsarnet* + +bookkeeper1*: + image: apachepulsar/pulsar-test-latest-version:latest + await: + strategy: org.apache.pulsar.tests.NoopAwaitStrategy + env: + - zkServers=zookeeper + - useHostNameAsBookieID=true + labels: + cluster: test + service: bookie + entryPoint: [bin/run-bookie.sh] + beforeStop: + - customBeforeStopAction: + strategy: org.apache.pulsar.tests.PulsarLogsToTargetDirStopAction + networkMode: pulsarnet* + +bookkeeper2*: + image: apachepulsar/pulsar-test-latest-version:latest + await: + strategy: org.apache.pulsar.tests.NoopAwaitStrategy + env: + - zkServers=zookeeper + - useHostNameAsBookieID=true + labels: + cluster: test + service: bookie + entryPoint: [bin/run-bookie.sh] + beforeStop: + - customBeforeStopAction: + strategy: org.apache.pulsar.tests.PulsarLogsToTargetDirStopAction + networkMode: pulsarnet* + +bookkeeper3*: + image: apachepulsar/pulsar-test-latest-version:latest + await: + strategy: org.apache.pulsar.tests.NoopAwaitStrategy + env: + - zkServers=zookeeper + - useHostNameAsBookieID=true + labels: + cluster: test + service: bookie + entryPoint: [bin/run-bookie.sh] + beforeStop: + - customBeforeStopAction: + strategy: org.apache.pulsar.tests.PulsarLogsToTargetDirStopAction + networkMode: pulsarnet* + +pulsar-broker1*: + image: apachepulsar/pulsar-test-latest-version:latest + await: + strategy: org.apache.pulsar.tests.NoopAwaitStrategy + aliases: + - pulsar-broker1 + env: + - zookeeperServers=zookeeper + - globalZookeeperServers=global-zookeeper:2184 + - clusterName=test + - NO_AUTOSTART=true + labels: + cluster: test + service: pulsar-broker + entryPoint: [bin/run-broker.sh] + beforeStop: + - customBeforeStopAction: + strategy: org.apache.pulsar.tests.PulsarLogsToTargetDirStopAction + networkMode: pulsarnet* + +pulsar-broker2*: + image: apachepulsar/pulsar-test-latest-version:latest + await: + strategy: org.apache.pulsar.tests.NoopAwaitStrategy + aliases: + - pulsar-broker2 + env: + - zookeeperServers=zookeeper + - globalZookeeperServers=global-zookeeper:2184 + - clusterName=test + - NO_AUTOSTART=true + labels: + cluster: test + service: pulsar-broker + entryPoint: [bin/run-broker.sh] + beforeStop: + - customBeforeStopAction: + strategy: org.apache.pulsar.tests.PulsarLogsToTargetDirStopAction + networkMode: pulsarnet* + +pulsar-proxy*: + image: apachepulsar/pulsar-test-latest-version:latest + await: + strategy: org.apache.pulsar.tests.NoopAwaitStrategy + aliases: + - pulsar-broker2 + env: + - zookeeperServers=zookeeper + - globalZookeeperServers=global-zookeeper:2184 + - clusterName=test + - NO_AUTOSTART=true + labels: + cluster: test + service: pulsar-proxy + entryPoint: [bin/run-proxy.sh] + beforeStop: + - customBeforeStopAction: + strategy: org.apache.pulsar.tests.PulsarLogsToTargetDirStopAction + networkMode: pulsarnet* + + diff --git a/tests/pom.xml b/tests/pom.xml index 5c8429d..220c7ca 100644 --- a/tests/pom.xml +++ b/tests/pom.xml @@ -34,6 +34,7 @@ <modules> <module>docker-images</module> <module>integration-tests-utils</module> + <module>integration-tests-topologies</module> </modules> <build> <plugins> -- To stop receiving notification emails like this one, please contact mme...@apache.org.