Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: PlaytikaOSS/testcontainers-spring-boot
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 3.1.4
Choose a base ref
...
head repository: PlaytikaOSS/testcontainers-spring-boot
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: refs/heads/develop
Choose a head ref
Loading
Showing with 684 additions and 384 deletions.
  1. +3 −2 .github/renovate/renovate.json
  2. +1 −1 .github/workflows/changelog-release-drafter.yml
  3. +6 −2 .github/workflows/maven.yml
  4. +16 −4 .github/workflows/release-support-stream.yml
  5. +2 −2 .github/workflows/release.yml
  6. +1 −1 .github/workflows/renovate.yml
  7. +1 −1 .mvn/wrapper/maven-wrapper.properties
  8. +3 −3 README.adoc
  9. +1 −1 embedded-aerospike-enterprise/README.adoc
  10. +1 −6 embedded-aerospike-enterprise/pom.xml
  11. +17 −15 ...src/main/java/com/playtika/testcontainers/aerospike/enterprise/AerospikeEnterpriseConfigurer.java
  12. +40 −0 ...terprise/src/main/java/com/playtika/testcontainers/aerospike/enterprise/AsadmCommandExecutor.java
  13. +2 −1 ...ytika/testcontainers/aerospike/enterprise/EnterpriseAerospikeTestOperationsAutoConfiguration.java
  14. +1 −1 embedded-aerospike-enterprise/src/main/resources/embedded-enterprise-aerospike.properties
  15. +30 −0 ...rise/src/test/java/com/playtika/testcontainers/aerospike/enterprise/AsadmCommandExecutorTest.java
  16. +2 −2 ...ka/testcontainers/aerospike/enterprise/ValidateEnterpriseAerospikeBootstrapConfigurationTest.java
  17. +1 −1 embedded-aerospike-enterprise/src/test/resources/log4j2.xml
  18. +1 −1 embedded-aerospike/README.adoc
  19. +1 −1 embedded-aerospike/pom.xml
  20. +1 −1 embedded-aerospike/src/main/java/com/playtika/testcontainer/aerospike/AerospikeProperties.java
  21. +1 −1 embedded-artifactory/README.adoc
  22. +1 −1 embedded-artifactory/pom.xml
  23. +1 −1 embedded-artifactory/src/main/java/com/playtika/testcontainer/artifactory/ArtifactoryProperties.java
  24. +1 −1 embedded-azurite/README.adoc
  25. +1 −1 embedded-azurite/pom.xml
  26. +1 −1 embedded-azurite/src/main/java/com/playtika/testcontainer/azurite/AzuriteProperties.java
  27. +10 −1 ...urite/src/main/java/com/playtika/testcontainer/azurite/EmbeddedAzuriteBootstrapConfiguration.java
  28. +1 −1 embedded-cassandra/pom.xml
  29. +1 −1 embedded-clickhouse/README.adoc
  30. +1 −1 embedded-clickhouse/pom.xml
  31. +1 −1 embedded-clickhouse/src/main/java/com/playtika/testcontainer/clickhouse/ClickHouseProperties.java
  32. +1 −1 embedded-cockroachdb/README.adoc
  33. +1 −1 embedded-cockroachdb/pom.xml
  34. +1 −1 embedded-cockroachdb/src/main/java/com/playtika/testcontainer/cockroach/CockroachDBProperties.java
  35. +1 −1 embedded-consul/pom.xml
  36. +1 −1 embedded-couchbase/README.adoc
  37. +6 −2 embedded-couchbase/pom.xml
  38. +1 −1 embedded-couchbase/src/main/java/com/playtika/testcontainer/couchbase/CouchbaseProperties.java
  39. +2 −2 embedded-db2/pom.xml
  40. +17 −1 embedded-dynamodb/pom.xml
  41. +1 −1 embedded-dynamodb/src/main/java/com/playtika/testcontainer/dynamodb/DynamoDBProperties.java
  42. +5 −4 embedded-dynamodb/src/test/java/com/playtika/testcontainer/dynamodb/springdata/DynamoDBConfig.java
  43. +1 −1 embedded-elasticsearch/README.adoc
  44. +1 −1 embedded-elasticsearch/pom.xml
  45. +1 −1 ...elasticsearch/src/main/java/com/playtika/testcontainer/elasticsearch/ElasticSearchProperties.java
  46. +2 −2 embedded-git/pom.xml
  47. +4 −4 embedded-git/src/main/java/com/playtika/testcontainer/git/EmbeddedGitBootstrapConfiguration.java
  48. +1 −1 embedded-git/src/main/java/com/playtika/testcontainer/git/GitProperties.java
  49. +10 −0 embedded-git/src/test/java/EmbeddedGitBootstrapConfigurationTest.java
  50. +1 −1 embedded-google-pubsub/README.adoc
  51. +1 −1 embedded-google-pubsub/pom.xml
  52. +1 −1 embedded-google-pubsub/src/main/java/com/playtika/testcontainer/pubsub/PubsubProperties.java
  53. +1 −1 embedded-google-storage/README.adoc
  54. +1 −1 embedded-google-storage/pom.xml
  55. +1 −1 embedded-google-storage/src/main/java/com/playtika/testcontainer/storage/StorageProperties.java
  56. +1 −1 embedded-grafana/README.adoc
  57. +1 −1 embedded-grafana/pom.xml
  58. +1 −1 embedded-grafana/src/main/java/com/playtika/testcontainer/grafana/GrafanaProperties.java
  59. +1 −1 embedded-influxdb/pom.xml
  60. +2 −2 embedded-k3s/README.adoc
  61. +2 −2 embedded-k3s/pom.xml
  62. +1 −1 embedded-k3s/src/main/java/com/playtika/testcontainer/k3s/K3sProperties.java
  63. +1 −1 embedded-k3s/src/main/resources/META-INF/additional-spring-configuration-metadata.json
  64. +2 −1 embedded-kafka/README.adoc
  65. +4 −4 embedded-kafka/pom.xml
  66. +1 −1 ...kafka/src/main/java/com/playtika/testcontainer/kafka/properties/KafkaConfigurationProperties.java
  67. +1 −1 .../main/java/com/playtika/testcontainer/kafka/properties/SchemaRegistryConfigurationProperties.java
  68. +1 −1 embedded-keycloak/README.adoc
  69. +2 −2 embedded-keycloak/pom.xml
  70. +1 −1 embedded-keycloak/src/main/java/com/playtika/testcontainer/keycloak/KeycloakProperties.java
  71. +1 −1 embedded-keycloak/src/main/resources/META-INF/additional-spring-configuration-metadata.json
  72. +23 −15 embedded-keycloak/src/test/resources/test-realm.json
  73. +1 −1 embedded-keydb/pom.xml
  74. +1 −2 ...-keydb/src/test/java/com/playtika/testcontainer/keydb/clustered/BaseClusterEmbeddedKeyDbTest.java
  75. +32 −66 ...db/src/test/java/com/playtika/testcontainer/keydb/standalone/BaseStandaloneEmbeddedKeyDbTest.java
  76. +2 −2 embedded-keydb/src/test/resources/application-enabled.properties
  77. +1 −1 embedded-localstack/README.adoc
  78. +2 −2 embedded-localstack/pom.xml
  79. +1 −1 embedded-localstack/src/main/java/com/playtika/testcontainer/localstack/LocalStackProperties.java
  80. +1 −1 embedded-localstack/src/main/resources/META-INF/additional-spring-configuration-metadata.json
  81. +1 −1 embedded-mailhog/pom.xml
  82. +1 −1 embedded-mariadb/pom.xml
  83. +1 −1 embedded-memsql/README.adoc
  84. +1 −1 embedded-memsql/pom.xml
  85. +1 −0 ...-memsql/src/main/java/com/playtika/testcontainer/memsql/EmbeddedMemSqlBootstrapConfiguration.java
  86. +1 −1 embedded-memsql/src/main/java/com/playtika/testcontainer/memsql/MemSqlProperties.java
  87. +2 −2 embedded-minio/pom.xml
  88. +1 −1 embedded-mockserver/pom.xml
  89. +1 −1 embedded-mongodb/README.adoc
  90. +1 −1 embedded-mongodb/pom.xml
  91. +2 −1 ...ngodb/src/main/java/com/playtika/testcontainer/mongodb/EmbeddedMongodbBootstrapConfiguration.java
  92. +5 −4 embedded-mongodb/src/main/java/com/playtika/testcontainer/mongodb/MongodbProperties.java
  93. +1 −1 embedded-mongodb/src/main/resources/META-INF/additional-spring-configuration-metadata.json
  94. +1 −1 embedded-mssqlserver/README.adoc
  95. +2 −2 embedded-mssqlserver/pom.xml
  96. +1 −1 embedded-mssqlserver/src/main/java/com/playtika/testcontainer/mssqlserver/MSSQLServerProperties.java
  97. +0 −1 embedded-mssqlserver/src/test/resources/bootstrap.properties
  98. +1 −1 embedded-mysql/README.adoc
  99. +1 −1 embedded-mysql/pom.xml
  100. +1 −1 embedded-mysql/src/main/java/com/playtika/testcontainer/mysql/MySQLProperties.java
  101. +3 −3 ...d-mysql/src/test/java/com/playtika/testcontainer/mysql/AutoConfiguredDatasourceDependsOnTest.java
  102. +5 −5 ...mysql/src/test/java/com/playtika/testcontainer/mysql/EmbeddedMySQLBootstrapConfigurationTest.java
  103. +2 −2 embedded-nats/pom.xml
  104. +1 −1 embedded-neo4j/README.adoc
  105. +2 −2 embedded-neo4j/pom.xml
  106. +1 −1 embedded-neo4j/src/main/java/com/playtika/testcontainer/neo4j/Neo4jProperties.java
  107. +1 −1 embedded-opensearch/README.adoc
  108. +3 −3 embedded-opensearch/pom.xml
  109. +2 −1 ...ed-opensearch/src/main/java/com/playtika/testcontainer/opensearch/OpenSearchContainerFactory.java
  110. +2 −2 embedded-opensearch/src/main/java/com/playtika/testcontainer/opensearch/OpenSearchProperties.java
  111. +1 −1 embedded-oracle-xe/pom.xml
  112. +1 −1 embedded-postgresql/README.adoc
  113. +2 −2 embedded-postgresql/pom.xml
  114. +0 −8 ...src/main/java/com/playtika/testcontainer/postgresql/EmbeddedPostgreSQLBootstrapConfiguration.java
  115. +1 −1 embedded-postgresql/src/main/java/com/playtika/testcontainer/postgresql/PostgreSQLProperties.java
  116. +1 −1 embedded-postgresql/src/main/resources/META-INF/additional-spring-configuration-metadata.json
  117. +1 −1 embedded-prometheus/README.adoc
  118. +1 −1 embedded-prometheus/pom.xml
  119. +1 −1 embedded-prometheus/src/main/java/com/playtika/testcontainer/prometheus/PrometheusProperties.java
  120. +1 −1 embedded-pulsar/README.adoc
  121. +14 −2 embedded-pulsar/pom.xml
  122. +1 −1 embedded-pulsar/src/main/java/com/playtika/testcontainer/pulsar/PulsarProperties.java
  123. +23 −3 embedded-rabbitmq/README.adoc
  124. +6 −1 embedded-rabbitmq/pom.xml
  125. +16 −1 ...tmq/src/main/java/com/playtika/testcontainer/rabbitmq/EmbeddedRabbitMQBootstrapConfiguration.java
  126. +1 −1 embedded-rabbitmq/src/main/java/com/playtika/testcontainer/rabbitmq/RabbitMQProperties.java
  127. +32 −0 ...bbitmq/src/test/java/com/playtika/testcontainer/rabbitmq/EmbeddedRabbitMQAdditionalPortsTest.java
  128. +0 −5 embedded-rabbitmq/src/test/resources/application-enabled.properties
  129. +7 −0 embedded-rabbitmq/src/test/resources/application-enabled.yml
  130. +8 −0 embedded-rabbitmq/src/test/resources/application-stream.yml
  131. +0 −1 embedded-rabbitmq/src/test/resources/bootstrap-plugins.properties
  132. +4 −0 embedded-rabbitmq/src/test/resources/bootstrap-plugins.yml
  133. +6 −0 embedded-rabbitmq/src/test/resources/bootstrap-stream.yml
  134. +1 −1 embedded-redis/README.adoc
  135. +6 −1 embedded-redis/pom.xml
  136. +1 −1 embedded-redis/src/main/java/com/playtika/testcontainer/redis/RedisProperties.java
  137. +1 −2 ...-redis/src/test/java/com/playtika/testcontainer/redis/clustered/BaseClusterEmbeddedRedisTest.java
  138. +1 −38 ...is/src/test/java/com/playtika/testcontainer/redis/standalone/BaseStandaloneEmbeddedRedisTest.java
  139. +2 −2 embedded-redis/src/test/resources/application-enabled.properties
  140. +1 −1 embedded-selenium/pom.xml
  141. +1 −1 embedded-solr/README.adoc
  142. +2 −2 embedded-solr/pom.xml
  143. +1 −1 embedded-solr/src/main/java/com/playtika/testcontainer/solr/SolrProperties.java
  144. +1 −1 embedded-spicedb/README.adoc
  145. +11 −4 embedded-spicedb/pom.xml
  146. +1 −1 embedded-spicedb/src/main/java/com/playtika/testcontainer/spicedb/SpiceDBProperties.java
  147. +6 −7 ...b/src/test/java/com/playtika/testcontainer/spicedb/EmbeddedSpiceDbBootstrapConfigurationTest.java
  148. +1 −1 embedded-toxiproxy/README.adoc
  149. +1 −1 embedded-toxiproxy/pom.xml
  150. +1 −1 embedded-toxiproxy/src/main/java/com/playtika/testcontainer/toxiproxy/ToxiProxyProperties.java
  151. +1 −1 embedded-vault/pom.xml
  152. +2 −2 embedded-vertica/pom.xml
  153. +6 −2 ...rtica/src/main/java/com/playtika/testcontainer/vertica/EmbeddedVerticaBootstrapConfiguration.java
  154. +19 −0 ...d-vertica/src/test/java/com/playtika/testcontainer/vertica/NetworkBootstrapTestConfiguration.java
  155. +80 −0 embedded-vertica/src/test/java/com/playtika/testcontainer/vertica/NetworkConfigurationTest.java
  156. +3 −0 embedded-vertica/src/test/resources/META-INF/spring.factories
  157. +1 −1 embedded-victoriametrics/README.adoc
  158. +1 −1 embedded-victoriametrics/pom.xml
  159. +1 −1 ...iametrics/src/main/java/com/playtika/testcontainer/victoriametrics/VictoriaMetricsProperties.java
  160. +1 −1 embedded-wiremock/README.adoc
  161. +1 −1 embedded-wiremock/pom.xml
  162. +1 −1 embedded-wiremock/src/main/java/com/playtika/testcontainers/wiremock/WiremockProperties.java
  163. +2 −2 embedded-zookeeper/pom.xml
  164. +1 −1 ...okeeper/src/main/java/com/playtika/testcontainers/zookeeper/ZookeeperConfigurationProperties.java
  165. +36 −14 pom.xml
  166. +1 −1 testcontainers-common/pom.xml
  167. +2 −0 ...-common/src/main/java/com/playtika/testcontainer/common/properties/CommonContainerProperties.java
  168. +1 −1 testcontainers-spring-boot-bom/pom.xml
  169. +8 −8 testcontainers-spring-boot-parent/pom.xml
5 changes: 3 additions & 2 deletions .github/renovate/renovate.json
Original file line number Diff line number Diff line change
@@ -25,8 +25,9 @@
"description": "Process update docker images",
"fileMatch": [
"^.*Properties\\.java$",
"^.*\\.properties",
"^.*\\.adoc",
"^.*additional-spring-configuration-metadata.json"
"^.*additional-spring-configuration-metadata\\.json"
],
"matchStrings": [
"\\/\\/.*?renovate:.*?datasource=(?<datasource>.*?)\\s+?return\\s+?\\\"(?<depName>.*?):?(?<currentValue>[\\w+\\.\\-]*)\"",
@@ -61,7 +62,7 @@
{
"description": "Process update images in spring configuration metadata",
"fileMatch": [
"^.*additional-spring-configuration-metadata.json"
"^.*additional-spring-configuration-metadata\\.json"
],
"matchStrings": [
"\\\"embedded\\.\\w+?\\.(dockerImage|docker\\-image)\\\",\\s+.*\\s+.*\\s+\\\"value\\\"\\s*?:\\s*?\"(?<depName>.*?):?(?<currentValue>[\\w+\\.\\-]*)\""
2 changes: 1 addition & 1 deletion .github/workflows/changelog-release-drafter.yml
Original file line number Diff line number Diff line change
@@ -10,6 +10,6 @@ jobs:
update_release_draft:
runs-on: ubuntu-latest
steps:
- uses: release-drafter/release-drafter@v5
- uses: release-drafter/release-drafter@v6
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
8 changes: 6 additions & 2 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
@@ -37,7 +37,11 @@ jobs:
- name: Set up JDK
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: '17'
distribution: 'corretto'
java-version: '21'
- name: Build with Maven
run: ./mvnw -version && whoami && umask -S && umask a+rw && umask -S && ./mvnw clean verify -P docker-clean -Dhttp.keepAlive=false -Dmaven.wagon.http.pool=false -Dmaven.wagon.http.retryHandler.count=3 --no-snapshot-updates --batch-mode --no-transfer-progress
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v5
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
20 changes: 16 additions & 4 deletions .github/workflows/release-support-stream.yml
Original file line number Diff line number Diff line change
@@ -12,7 +12,19 @@ on:
branch:
description: "Branch to be released"
required: true
type: string
default: 'support/2.3.X'
type: choice
options:
- 'support/2.3.X'
- 'support/3.0.X'
java-version:
description: "Java version"
required: true
default: '21'
type: choice
options:
- '21'
- '17'

jobs:
publish:
@@ -27,8 +39,8 @@ jobs:
- name: Set up JDK
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: '17'
distribution: 'corretto'
java-version: ${{github.event.inputs.java-version}}
server-id: ossrh
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
@@ -50,7 +62,7 @@ jobs:

- name: Commit & Push changes
if: ${{ success() }}
uses: actions-js/push@v1.4
uses: actions-js/push@v1.5
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
message: 'Release ${{github.event.inputs.version}}'
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -17,8 +17,8 @@ jobs:
- name: Set up JDK
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: '17'
distribution: 'corretto'
java-version: '21'
server-id: ossrh
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
2 changes: 1 addition & 1 deletion .github/workflows/renovate.yml
Original file line number Diff line number Diff line change
@@ -30,7 +30,7 @@ jobs:
uses: actions/checkout@v4

- name: Self-hosted Renovate
uses: renovatebot/github-action@v39.2.4
uses: renovatebot/github-action@v41.0.14
with:
configurationFile: .github/renovate/renovate.json
token: ${{ secrets.RELEASE_PERSONAL_ACCESS_TOKEN }}
2 changes: 1 addition & 1 deletion .mvn/wrapper/maven-wrapper.properties
Original file line number Diff line number Diff line change
@@ -14,5 +14,5 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.1/apache-maven-3.9.1-bin.zip
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.6/apache-maven-3.9.6-bin.zip
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar
6 changes: 3 additions & 3 deletions README.adoc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
= Testcontainers Spring Boot

https://codecov.io/gh/Playtika/testcontainers-spring-boot[image:https://codecov.io/gh/testcontainers/testcontainers-spring-boot/branch/develop/graph/badge.svg[codecov]]
https://codecov.io/gh/PlaytikaOSS/testcontainers-spring-boot[image:https://codecov.io/gh/PlaytikaOSS/testcontainers-spring-boot/graph/badge.svg?token=9E0VBFIB5B[codecov]]
https://maven-badges.herokuapp.com/maven-central/com.playtika.testcontainers/testcontainers-spring-boot[image:https://maven-badges.herokuapp.com/maven-central/com.playtika.testcontainers/testcontainers-spring-boot/badge.svg[Maven Central]]

If you develop services using Spring Boot and maybe Spring Cloud and you do
@@ -16,10 +16,10 @@ Usage of Spring Cloud in your production code is optional, but __you will need i
|===
| Spring Boot | Test Containers Spring Boot

|2.4.X, 2.5.X, 2.6.X, 2.7.X
|2.5.X, 2.6.X, 2.7.X
|2.X.X

|2.7.X, 3.0.X, 3.1.X
|3.0.X, 3.1.X
|3.0.X

|3.2.X
2 changes: 1 addition & 1 deletion embedded-aerospike-enterprise/README.adoc
Original file line number Diff line number Diff line change
@@ -24,7 +24,7 @@ ToxiProxy is a great tool for simulating network conditions, meaning that you ca

* `embedded.aerospike.enabled` `(true|false, default is 'true')`
* `embedded.aerospike.reuseContainer` `(true|false, default is 'false')`
* `embedded.aerospike.dockerImage` `(default is set to 'aerospike/aerospike-server-enterprise:6.4.0.10')`
* `embedded.aerospike.dockerImage` `(default is set to 'aerospike/aerospike-server-enterprise:8.0.0.5')`
** Aerospike Enterprise version must be not less then 6.3.0
* `embedded.aerospike.featureKey` base64 of a feature-key-file https://aerospike.com/docs/server/operations/configure/feature-key, default is null.
**Warning: if not provided, the Aerospike Database EE evaluation feature key file will be used. That means you can use it internally only for Evaluation
7 changes: 1 addition & 6 deletions embedded-aerospike-enterprise/pom.xml
Original file line number Diff line number Diff line change
@@ -7,7 +7,7 @@
<parent>
<artifactId>testcontainers-spring-boot-parent</artifactId>
<groupId>com.playtika.testcontainers</groupId>
<version>3.1.3</version>
<version>3.1.11</version>
<relativePath>../testcontainers-spring-boot-parent</relativePath>
</parent>

@@ -32,10 +32,5 @@
<groupId>com.playtika.testcontainers</groupId>
<artifactId>embedded-aerospike</artifactId>
</dependency>
<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-core</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
</project>
Original file line number Diff line number Diff line change
@@ -3,7 +3,6 @@
import com.playtika.testcontainer.aerospike.AerospikeProperties;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.testcontainers.containers.Container;
import org.testcontainers.containers.GenericContainer;

import java.io.IOException;
@@ -15,26 +14,29 @@ public class AerospikeEnterpriseConfigurer {
private final AerospikeProperties aerospikeProperties;
private final AerospikeEnterpriseProperties enterpriseProperties;

public void configure(GenericContainer<?> aerospikeContainer) throws IOException, InterruptedException {
public void configure(GenericContainer<?> aerospikeContainer) throws IOException, InterruptedException {
if (aerospikeProperties.getFeatureKey() == null || aerospikeProperties.getFeatureKey().isBlank()) {
log.warn("Evaluation feature key file not provided by 'embedded.aerospike.featureKey' property. " +
"Pay attention to license details: https://github.com/aerospike/aerospike-server.docker/blob/master/enterprise/ENTERPRISE_LICENSE");
}

setupDisallowExpunge(aerospikeContainer);
}

private void setupDisallowExpunge(GenericContainer<?> aerospikeContainer) throws IOException, InterruptedException {
if (!enterpriseProperties.isDurableDeletes()) {
return;
}
log.info("Setting up 'disallow-expunge' to true...");
String namespace = aerospikeProperties.getNamespace();
Container.ExecResult result = aerospikeContainer.execInContainer("asadm", "-e",
String.format("enable; manage config namespace %s param disallow-expunge to true", namespace));
if (result.getStderr().length() > 0) {
throw new IllegalStateException("Failed to set up 'disallow-expunge' to true: " + result.getStderr());
AsadmCommandExecutor asadmCommandExecutor = new AsadmCommandExecutor(aerospikeContainer);

/*
By default, the value of this metric is 90%, we set it to 100% to prevent stopping writes for the Aerospike
Enterprise container during high consumption of system memory. For the Aerospike Community Edition, this metric is not used.
Documentation: https://aerospike.com/docs/server/reference/configuration#stop-writes-sys-memory-pct
*/
log.info("Switching off 'stop-writes-sys-memory-pct'... ");
asadmCommandExecutor.execute(String.format("manage config namespace %s param stop-writes-sys-memory-pct to 100", namespace));
log.info("Success switching off 'stop-writes-sys-memory-pct'");

if (enterpriseProperties.isDurableDeletes()) {
log.info("Setting up 'disallow-expunge' to true...");
asadmCommandExecutor.execute(String.format("manage config namespace %s param disallow-expunge to true", namespace));
log.info("Success setting up 'disallow-expunge' to true");
}
log.info("Set up 'disallow-expunge' to true: {}", result.getStdout());
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
package com.playtika.testcontainers.aerospike.enterprise;

import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.testcontainers.containers.Container;
import org.testcontainers.containers.GenericContainer;

import java.io.IOException;

@RequiredArgsConstructor
@Slf4j
public class AsadmCommandExecutor {

private final GenericContainer<?> aerospikeContainer;

public void execute(String command) throws IOException, InterruptedException {
Container.ExecResult result = aerospikeContainer.execInContainer("asadm", "--enable", "-e", command);
logStdout(result);
if (result.getExitCode() != 0 || isBadResponse(result)) {
throw new IllegalStateException(String.format("Failed to execute \"asadm --enable -e '%s'\":\nstdout:\n%s\nstderr:\n%s",
command, result.getStdout(), result.getStderr()));
}
}

private boolean isBadResponse(Container.ExecResult execResult) {
String stdout = execResult.getStdout();
/*
Example of the stdout without error:
~Set Namespace Param stop-writes-sys-memory-pct to 100~
Node|Response
728bb242e58c:3000|ok
Number of rows: 1
*/
return !stdout.contains("|ok");
}

private static void logStdout(Container.ExecResult result) {
log.debug("Aerospike asadm util stdout: \n{}\n{}", result.getStdout(), result.getStderr());
}
}
Original file line number Diff line number Diff line change
@@ -21,8 +21,9 @@ public class EnterpriseAerospikeTestOperationsAutoConfiguration {
@Bean
@ConditionalOnProperty(value = "embedded.aerospike.time-travel.enabled", havingValue = "true", matchIfMissing = true)
public ExpiredDocumentsCleaner expiredDocumentsCleaner(IAerospikeClient client,
AerospikeEnterpriseProperties aerospikeEnterpriseProperties,
AerospikeProperties properties) {
return new AerospikeExpiredDocumentsCleaner(client, properties.getNamespace(), true);
return new AerospikeExpiredDocumentsCleaner(client, properties.getNamespace(), aerospikeEnterpriseProperties.isDurableDeletes());
}

}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
embedded.aerospike.dockerImage=aerospike/aerospike-server-enterprise:6.3.0.16
embedded.aerospike.dockerImage=aerospike/aerospike-server-enterprise:7.0.0.4
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
package com.playtika.testcontainers.aerospike.enterprise;

import com.playtika.testcontainer.aerospike.AerospikeProperties;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.testcontainers.containers.GenericContainer;

import static org.assertj.core.api.Assertions.assertThatExceptionOfType;

public class AsadmCommandExecutorTest extends BaseEnterpriseAerospikeTest {

@Autowired
@Qualifier(AerospikeProperties.BEAN_NAME_AEROSPIKE)
private GenericContainer<?> aerospikeContainer;

@Test
public void shouldFailCommandExecutionWithBadOption() {
AsadmCommandExecutor commandExecutor = new AsadmCommandExecutor(aerospikeContainer);
assertThatExceptionOfType(IllegalStateException.class)
.isThrownBy(() -> commandExecutor.execute("-tttttt"));
}

@Test
public void shouldFailCommandExecutionWithBadCommand() {
AsadmCommandExecutor commandExecutor = new AsadmCommandExecutor(aerospikeContainer);
assertThatExceptionOfType(IllegalStateException.class)
.isThrownBy(() -> commandExecutor.execute("manage config namespace NAMESPACE_NOT_EXISTS param disallow-expunge to true"));
}
}
Original file line number Diff line number Diff line change
@@ -20,13 +20,13 @@ void failOnNonEnterpriseImage() {

@Test
void failOnUnsuitableEnterpriseImageVersion() {
contextRunner.withPropertyValues("embedded.aerospike.dockerImage=aerospike/aerospike-server-enterprise:6.1.0.16_1")
contextRunner.withPropertyValues("embedded.aerospike.dockerImage=aerospike/aerospike-server-enterprise:6.1.0.16")
.run(context -> assertThat(context).hasFailed());
}

@Test
void skipValidation() {
contextRunner.withPropertyValues("embedded.aerospike.dockerImage=aerospike-server:6.1.0.16_1",
contextRunner.withPropertyValues("embedded.aerospike.dockerImage=aerospike-server:6.1.0.16",
"embedded.aerospike.enabled=false")
.run(context -> assertThat(context).hasNotFailed());

Original file line number Diff line number Diff line change
@@ -6,7 +6,7 @@
</Console>
</Appenders>
<Loggers>
<Logger name="com.playtika.testcontainer" level="info"/>
<Logger name="com.playtika.testcontainers" level="info"/>
<Logger name="org.springframework" level="error"/>
<Root level="error">
<AppenderRef ref="Console"/>
2 changes: 1 addition & 1 deletion embedded-aerospike/README.adoc
Original file line number Diff line number Diff line change
@@ -19,7 +19,7 @@ ToxiProxy is a great tool for simulating network conditions, meaning that you ca

* `embedded.aerospike.enabled` `(true|false, default is 'true')`
* `embedded.aerospike.reuseContainer` `(true|false, default is 'false')`
* `embedded.aerospike.dockerImage` `(default is set to 'aerospike/aerospike-server:6.4.0.10')`
* `embedded.aerospike.dockerImage` `(default is set to 'aerospike/aerospike-server:8.0.0.5')`
** You can pick wanted version on https://hub.docker.com/_/aerospike/tags[dockerhub]
* `embedded.aerospike.featureKey` `(base64 of a feature-key-file https://aerospike.com/docs/server/operations/configure/feature-key, default is null) is only required for the EE image`
* `embedded.aerospike.waitTimeoutInSeconds` `(default is 60 seconds)`
2 changes: 1 addition & 1 deletion embedded-aerospike/pom.xml
Original file line number Diff line number Diff line change
@@ -7,7 +7,7 @@
<parent>
<artifactId>testcontainers-spring-boot-parent</artifactId>
<groupId>com.playtika.testcontainers</groupId>
<version>3.1.3</version>
<version>3.1.11</version>
<relativePath>../testcontainers-spring-boot-parent</relativePath>
</parent>

Original file line number Diff line number Diff line change
@@ -24,6 +24,6 @@ public class AerospikeProperties extends CommonContainerProperties {
public String getDefaultDockerImage() {
// Please don`t remove this comment.
// renovate: datasource=docker
return "aerospike/aerospike-server:6.4.0.10";
return "aerospike/aerospike-server:8.0.0.5";
}
}
2 changes: 1 addition & 1 deletion embedded-artifactory/README.adoc
Original file line number Diff line number Diff line change
@@ -16,7 +16,7 @@

* `embedded.artifactory.enabled` `(true|false, default is true)`
* `embedded.artifactory.reuseContainer` `(true|false, default is false)`
* `embedded.artifactory.dockerImage` `(default is 'releases-docker.jfrog.io/jfrog/artifactory-oss:7.77.3')`
* `embedded.artifactory.dockerImage` `(default is 'releases-docker.jfrog.io/jfrog/artifactory-oss:7.77.12')`
** Release notes on https://www.jfrog.com/confluence/display/JFROG/Artifactory+Release+Notes[jfrog.com]
* `embedded.artifactory.networkAlias` `(default is 'artifactory')`
* `embedded.artifactory.username` `(default is 'admin')`
2 changes: 1 addition & 1 deletion embedded-artifactory/pom.xml
Original file line number Diff line number Diff line change
@@ -7,7 +7,7 @@
<parent>
<artifactId>testcontainers-spring-boot-parent</artifactId>
<groupId>com.playtika.testcontainers</groupId>
<version>3.1.3</version>
<version>3.1.11</version>
<relativePath>../testcontainers-spring-boot-parent</relativePath>
</parent>

Original file line number Diff line number Diff line change
@@ -27,6 +27,6 @@ public ArtifactoryProperties() {
public String getDefaultDockerImage() {
// Please don`t remove this comment.
// renovate: datasource=docker
return "releases-docker.jfrog.io/jfrog/artifactory-oss:7.77.3";
return "releases-docker.jfrog.io/jfrog/artifactory-oss:7.77.12";
}
}
2 changes: 1 addition & 1 deletion embedded-azurite/README.adoc
Original file line number Diff line number Diff line change
@@ -15,7 +15,7 @@
==== Consumes (via `bootstrap.properties`)
* `embedded.azurite.enabled` `(true|false, default is true)`
* `embedded.azurite.reuseContainer` `(true|false, default is false)`
* `embedded.azurite.dockerImage` `(default is 'mcr.microsoft.com/azure-storage/azurite')`
* `embedded.azurite.dockerImage` `(default is 'mcr.microsoft.com/azure-storage/azurite:3.33.0')`
** Image versions on https://hub.docker.com/_/microsoft-azure-storage-azurite
* `embedded.azurite.blobStoragePort` `(default is 10000)`
* `embedded.azurite.queueStoragePort` `(default is 10001)`
2 changes: 1 addition & 1 deletion embedded-azurite/pom.xml
Original file line number Diff line number Diff line change
@@ -5,7 +5,7 @@
<parent>
<artifactId>testcontainers-spring-boot-parent</artifactId>
<groupId>com.playtika.testcontainers</groupId>
<version>3.1.3</version>
<version>3.1.11</version>
<relativePath>../testcontainers-spring-boot-parent</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
Loading