This is an automated email from the ASF dual-hosted git repository.

zhangliang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git


The following commit(s) were added to refs/heads/master by this push:
     new b2d40b1e4a9 Use TreeMap for MountSQLResourceGenerator (#36640)
b2d40b1e4a9 is described below

commit b2d40b1e4a94c33abbde26513f600436c108a316
Author: Liang Zhang <[email protected]>
AuthorDate: Sat Sep 20 11:40:17 2025 +0800

    Use TreeMap for MountSQLResourceGenerator (#36640)
---
 .../adapter/impl/ShardingSphereProxyEmbeddedContainer.java       | 9 +++------
 .../env/container/storage/mount/MountSQLResourceGenerator.java   | 3 ++-
 2 files changed, 5 insertions(+), 7 deletions(-)

diff --git 
a/test/e2e/env/src/test/java/org/apache/shardingsphere/test/e2e/env/container/adapter/impl/ShardingSphereProxyEmbeddedContainer.java
 
b/test/e2e/env/src/test/java/org/apache/shardingsphere/test/e2e/env/container/adapter/impl/ShardingSphereProxyEmbeddedContainer.java
index 77687d708b5..a7d9f184cae 100644
--- 
a/test/e2e/env/src/test/java/org/apache/shardingsphere/test/e2e/env/container/adapter/impl/ShardingSphereProxyEmbeddedContainer.java
+++ 
b/test/e2e/env/src/test/java/org/apache/shardingsphere/test/e2e/env/container/adapter/impl/ShardingSphereProxyEmbeddedContainer.java
@@ -17,6 +17,7 @@
 
 package org.apache.shardingsphere.test.e2e.env.container.adapter.impl;
 
+import lombok.RequiredArgsConstructor;
 import lombok.SneakyThrows;
 import lombok.extern.slf4j.Slf4j;
 import org.apache.commons.io.IOUtils;
@@ -62,9 +63,10 @@ import java.util.concurrent.atomic.AtomicReference;
 
 /**
  * ShardingSphere proxy embedded container.
- * todo Reset static properties when closing the class., like 
PipelineAPIFactory#GOVERNANCE_FACADE_MAP
  */
+@RequiredArgsConstructor
 @Slf4j
+// TODO Reset static properties when closing the class., like 
PipelineAPIFactory#GOVERNANCE_FACADE_MAP
 public final class ShardingSphereProxyEmbeddedContainer implements 
AdapterContainer, EmbeddedITContainer {
     
     private static final String OS_MAC_TMP_DIR = "/tmp";
@@ -81,11 +83,6 @@ public final class ShardingSphereProxyEmbeddedContainer 
implements AdapterContai
     
     private ShardingSphereProxy proxy;
     
-    public ShardingSphereProxyEmbeddedContainer(final DatabaseType 
databaseType, final AdaptorContainerConfiguration config) {
-        this.databaseType = databaseType;
-        this.config = config;
-    }
-    
     @Override
     public DataSource getTargetDataSource(final String serverLists) {
         DataSource dataSource = targetDataSourceProvider.get();
diff --git 
a/test/e2e/env/src/test/java/org/apache/shardingsphere/test/e2e/env/container/storage/mount/MountSQLResourceGenerator.java
 
b/test/e2e/env/src/test/java/org/apache/shardingsphere/test/e2e/env/container/storage/mount/MountSQLResourceGenerator.java
index 6dbcdfca240..37b230d915a 100644
--- 
a/test/e2e/env/src/test/java/org/apache/shardingsphere/test/e2e/env/container/storage/mount/MountSQLResourceGenerator.java
+++ 
b/test/e2e/env/src/test/java/org/apache/shardingsphere/test/e2e/env/container/storage/mount/MountSQLResourceGenerator.java
@@ -28,6 +28,7 @@ import java.util.Collection;
 import java.util.LinkedList;
 import java.util.Map;
 import java.util.Optional;
+import java.util.TreeMap;
 import java.util.stream.Collectors;
 
 /**
@@ -68,7 +69,7 @@ public final class MountSQLResourceGenerator {
         for (String each : getToBeMountedScenarioSQLFiles(scenario)) {
             toBeMountedSQLFiles.add("/" + each);
         }
-        return toBeMountedSQLFiles.stream().collect(Collectors.toMap(each -> 
each, each -> "/docker-entrypoint-initdb.d/" + new File(each).getName()));
+        return new 
TreeMap<>(toBeMountedSQLFiles.stream().collect(Collectors.toMap(each -> each, 
each -> "/docker-entrypoint-initdb.d/" + new File(each).getName())));
     }
     
     private Optional<String> findToBeMountedCommonSQLFile(final String 
toBeMountedSQLFile) {

Reply via email to