diff --git a/MetadataMigration/src/test/java/org/opensearch/migrations/MultiTypeMappingTransformationTest.java b/MetadataMigration/src/test/java/org/opensearch/migrations/MultiTypeMappingTransformationTest.java index a5249c5ac..5f3a301f5 100644 --- a/MetadataMigration/src/test/java/org/opensearch/migrations/MultiTypeMappingTransformationTest.java +++ b/MetadataMigration/src/test/java/org/opensearch/migrations/MultiTypeMappingTransformationTest.java @@ -34,15 +34,13 @@ class MultiTypeMappingTransformationTest extends BaseMigrationTest { @SneakyThrows @Test public void multiTypeTransformationTest_union() { + log.atWarn().setMessage("Using temp dir {}") + .addArgument(this.localDirectory.toAbsolutePath().toString()) + .log(); try ( - final var volumeContainer = new GenericContainer<>("alpine:latest") - .withFileSystemBind(localDirectory.toAbsolutePath().toString(), SearchClusterContainer.CLUSTER_SNAPSHOT_DIR, BindMode.READ_WRITE); - ) { - volumeContainer.start(); - final var indexCreatedCluster = new SearchClusterContainer(SearchClusterContainer.ES_V5_6_16) - .withVolumesFrom(volumeContainer, BindMode.READ_WRITE); - + .withFileSystemBind(this.localDirectory.toAbsolutePath().toString(), SearchClusterContainer.CLUSTER_SNAPSHOT_DIR, BindMode.READ_WRITE); + ) { indexCreatedCluster.start(); var indexCreatedOperations = new ClusterOperations(indexCreatedCluster.getUrl()); @@ -60,10 +58,10 @@ public void multiTypeTransformationTest_union() { indexCreatedOperations.createSnapshotRepository(SearchClusterContainer.CLUSTER_SNAPSHOT_DIR, es5Repo); indexCreatedOperations.takeSnapshot(es5Repo, snapshotName, originalIndexName); -// indexCreatedCluster.copySnapshotData(localDirectory.getAbsolutePath()); + indexCreatedCluster.copySnapshotData(localDirectory.toAbsolutePath().toString()); final var upgradedSourceCluster = new SearchClusterContainer(ES_V6_8_23) - .withVolumesFrom(volumeContainer, BindMode.READ_WRITE) + .withFileSystemBind(localDirectory.toAbsolutePath().toString(), SearchClusterContainer.CLUSTER_SNAPSHOT_DIR, BindMode.READ_WRITE) .withLogConsumer(new Slf4jLogConsumer(LoggerFactory.getLogger("docker"))); final var targetCluster = new SearchClusterContainer(SearchClusterContainer.OS_V2_14_0);