You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by zh...@apache.org on 2026/08/01 10:43:40 UTC

(shardingsphere) branch master updated: Remove useless OraclePipelineNativeContainerDropTableOption (#39306)

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

terrymanu 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 1fe142b9c07 Remove useless OraclePipelineNativeContainerDropTableOption (#39306)
1fe142b9c07 is described below

commit 1fe142b9c07cc7916b1cd26e2fea96c38b35c13f
Author: Liang Zhang <zh...@apache.org>
AuthorDate: Sat Aug 1 18:43:35 2026 +0800

    Remove useless OraclePipelineNativeContainerDropTableOption (#39306)
---
 ...aclePipelineNativeContainerDropTableOption.java | 49 ----------------------
 ...PipelineNativeContainerDropTableOptionTest.java | 44 -------------------
 ...d.DialectPipelineNativeContainerDropTableOption |  1 -
 3 files changed, 94 deletions(-)

diff --git a/test/e2e/operation/pipeline/src/test/java/org/apache/shardingsphere/test/e2e/operation/pipeline/framework/container/compose/natived/dialect/OraclePipelineNativeContainerDropTableOption.java b/test/e2e/operation/pipeline/src/test/java/org/apache/shardingsphere/test/e2e/operation/pipeline/framework/container/compose/natived/dialect/OraclePipelineNativeContainerDropTableOption.java
deleted file mode 100644
index 879710f8758..00000000000
--- a/test/e2e/operation/pipeline/src/test/java/org/apache/shardingsphere/test/e2e/operation/pipeline/framework/container/compose/natived/dialect/OraclePipelineNativeContainerDropTableOption.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * 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.
- */
-
-package org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.dialect;
-
-import org.apache.shardingsphere.test.e2e.env.container.storage.option.StorageContainerConnectOption;
-import org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.DialectPipelineNativeContainerDropTableOption;
-
-import java.util.Optional;
-
-/**
- * Pipeline native container drop table option for Oracle.
- */
-public final class OraclePipelineNativeContainerDropTableOption implements DialectPipelineNativeContainerDropTableOption {
-    
-    @Override
-    public String getJdbcUrl(final StorageContainerConnectOption storageContainerConnectOption, final int actualDatabasePort, final String databaseName) {
-        return storageContainerConnectOption.getURL("localhost", actualDatabasePort, "");
-    }
-    
-    @Override
-    public String getQueryAllSchemaAndTableMapperSQL(final String databaseName) {
-        return String.format("SELECT OWNER, TABLE_NAME FROM ALL_TABLES WHERE OWNER='%s'", databaseName);
-    }
-    
-    @Override
-    public Optional<String> getDropSchemaSQL() {
-        return Optional.empty();
-    }
-    
-    @Override
-    public String getDatabaseType() {
-        return "Oracle";
-    }
-}
diff --git a/test/e2e/operation/pipeline/src/test/java/org/apache/shardingsphere/test/e2e/operation/pipeline/framework/container/compose/natived/dialect/OraclePipelineNativeContainerDropTableOptionTest.java b/test/e2e/operation/pipeline/src/test/java/org/apache/shardingsphere/test/e2e/operation/pipeline/framework/container/compose/natived/dialect/OraclePipelineNativeContainerDropTableOptionTest.java
deleted file mode 100644
index 626668ba435..00000000000
--- a/test/e2e/operation/pipeline/src/test/java/org/apache/shardingsphere/test/e2e/operation/pipeline/framework/container/compose/natived/dialect/OraclePipelineNativeContainerDropTableOptionTest.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * 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.
- */
-
-package org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.dialect;
-
-import org.apache.shardingsphere.database.connector.core.type.DatabaseType;
-import org.apache.shardingsphere.infra.spi.type.typed.TypedSPILoader;
-import org.apache.shardingsphere.test.e2e.env.container.storage.option.StorageContainerConnectOption;
-import org.junit.jupiter.api.Test;
-import org.mockito.MockedStatic;
-
-import static org.hamcrest.MatcherAssert.assertThat;
-import static org.hamcrest.Matchers.is;
-import static org.mockito.Mockito.mock;
-import static org.mockito.Mockito.mockStatic;
-import static org.mockito.Mockito.when;
-
-class OraclePipelineNativeContainerDropTableOptionTest {
-    
-    @Test
-    void assertGetJdbcUrl() {
-        DatabaseType databaseType = mock(DatabaseType.class);
-        StorageContainerConnectOption connectOption = mock(StorageContainerConnectOption.class);
-        when(connectOption.getURL("localhost", 1521, "")).thenReturn("jdbc:oracle:thin:@localhost:1521:XE");
-        try (MockedStatic<TypedSPILoader> typedSPILoader = mockStatic(TypedSPILoader.class)) {
-            typedSPILoader.when(() -> TypedSPILoader.getService(DatabaseType.class, "Oracle")).thenReturn(databaseType);
-            assertThat(new OraclePipelineNativeContainerDropTableOption().getJdbcUrl(connectOption, 1521, "pipeline_e2e_0"), is("jdbc:oracle:thin:@localhost:1521:XE"));
-        }
-    }
-}
diff --git a/test/e2e/operation/pipeline/src/test/resources/META-INF/services/org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.DialectPipelineNativeContainerDropTableOption b/test/e2e/operation/pipeline/src/test/resources/META-INF/services/org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.DialectPipelineNativeContainerDropTableOption
index fd97f16223b..fceea1d7826 100644
--- a/test/e2e/operation/pipeline/src/test/resources/META-INF/services/org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.DialectPipelineNativeContainerDropTableOption
+++ b/test/e2e/operation/pipeline/src/test/resources/META-INF/services/org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.DialectPipelineNativeContainerDropTableOption
@@ -17,6 +17,5 @@
 
 org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.dialect.MySQLPipelineNativeContainerDropTableOption
 org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.dialect.PostgreSQLPipelineNativeContainerDropTableOption
-org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.dialect.OraclePipelineNativeContainerDropTableOption
 org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.dialect.MariaDBPipelineNativeContainerDropTableOption
 org.apache.shardingsphere.test.e2e.operation.pipeline.framework.container.compose.natived.dialect.OpenGaussPipelineNativeContainerDropTableOption