Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ ShardingSphere 默认情况下仅包含核心 SPI 的实现,在 Git Source 存
- 行表达式
- `org.apache.shardingsphere:shardingsphere-infra-expr-espresso`,基于 GraalVM Truffle 的 Espresso 实现的使用 Groovy 语法的行表达式
- 数据库类型识别
- `org.apache.shardingsphere:shardingsphere-infra-database-testcontainers`, 对 `testcontainers-java` 的 `JDBC support` 的 jdbcURL 的识别适配
- `org.apache.shardingsphere:shardingsphere-infra-database-hive`, 对 Hive 的 jdbcURL 的识别适配,元数据加载实现
- `org.apache.shardingsphere:shardingsphere-infra-database-presto`, 对 Presto 的 jdbcURL 的识别适配,元数据加载实现
- SQL 解析
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ All optional plugins are listed below in the form of `groupId:artifactId`.
- Row Value Expressions definition
- `org.apache.shardingsphere:shardingsphere-infra-expr-espresso`,Row Value Expressions that uses the Groovy syntax based on GraalVM Truffle's Espresso implementation
- Database type identification
- `org.apache.shardingsphere:shardingsphere-infra-database-testcontainers`, Adaptation of jdbcURL for `JDBC support` of `testcontainers-java`
- `org.apache.shardingsphere:shardingsphere-infra-database-hive`, Adaptation of jdbcURL for `JDBC support` of Hive, and metadata loading implementation
- `org.apache.shardingsphere:shardingsphere-infra-database-presto`, Adaptation of jdbcURL for `JDBC support` of Presto, and metadata loading implementation
- SQL parsing
Expand Down

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ ShardingSphere 默认情况下仅包含核心 SPI 的实现,在 Git Source 存
- 行表达式
- `org.apache.shardingsphere:shardingsphere-infra-expr-espresso`,基于 GraalVM Truffle 的 Espresso 实现的使用 Groovy 语法的行表达式
- 数据库类型识别
- `org.apache.shardingsphere:shardingsphere-infra-database-testcontainers`, 对 `testcontainers-java` 的 `JDBC support` 的 jdbcURL 的识别适配
- `org.apache.shardingsphere:shardingsphere-infra-database-hive`, 对 Hive 的 jdbcURL 的识别适配,元数据加载实现
- `org.apache.shardingsphere:shardingsphere-infra-database-presto`, 对 Presto 的 jdbcURL 的识别适配,元数据加载实现
- SQL 解析
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ All optional plugins are listed below in the form of `groupId:artifactId`.
- Row Value Expressions definition
- `org.apache.shardingsphere:shardingsphere-infra-expr-espresso`,Row Value Expressions that uses the Groovy syntax based on GraalVM Truffle's Espresso implementation
- Database type identification
- `org.apache.shardingsphere:shardingsphere-infra-database-testcontainers`, Adaptation of jdbcURL for `JDBC support` of `testcontainers-java`
- `org.apache.shardingsphere:shardingsphere-infra-database-hive`, Adaptation of jdbcURL for `JDBC support` of Hive, and metadata loading implementation
- `org.apache.shardingsphere:shardingsphere-infra-database-presto`, Adaptation of jdbcURL for `JDBC support` of Presto, and metadata loading implementation
- SQL parsing
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,23 +81,4 @@ void assertParseMicrosoftSQLServerJdbcUrl() {
void assertParseIncorrectURL() {
assertThrows(UnrecognizedDatabaseURLException.class, () -> new StandardJdbcUrlParser().parse("jdbc:h2:mem:test;DB_CLOSE_DELAY=-1;DATABASE_TO_UPPER=false;MODE=MySQL"));
}

@Test
void assertParseTestContainersJDBCUrl() {
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:mysql:5.7.34:///demo_ds").getDatabase(), is("demo_ds"));
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:postgresql:9.6.8:///demo_ds").getDatabase(), is("demo_ds"));
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:postgis:9.6-2.5:///demo_ds").getDatabase(), is("demo_ds"));
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:timescaledb:2.1.0-pg13:///demo_ds").getDatabase(), is("demo_ds"));
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:trino:352://localhost/memory/default").getDatabase(), is("memory/default"));
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:cockroach:v21.2.3:///demo_ds").getDatabase(), is("demo_ds"));
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:tidb:v6.1.0:///demo_ds").getDatabase(), is("demo_ds"));
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:mysql:5.7.34:///demo_ds?TC_INITSCRIPT=somepath/init_mysql.sql")
.getQueryProperties().getProperty("TC_INITSCRIPT"), is("somepath/init_mysql.sql"));
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:mysql:5.7.34:///demo_ds?TC_INITSCRIPT=file:src/main/resources/init_mysql.sql")
.getQueryProperties().getProperty("TC_INITSCRIPT"), is("file:src/main/resources/init_mysql.sql"));
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:mysql:5.7.34:///demo_ds?TC_INITFUNCTION=org.testcontainers.jdbc.JDBCDriverTest::sampleInitFunction")
.getQueryProperties().getProperty("TC_INITFUNCTION"), is("org.testcontainers.jdbc.JDBCDriverTest::sampleInitFunction"));
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:mysql:5.7.34:///demo_ds?TC_DAEMON=true").getQueryProperties().getProperty("TC_DAEMON"), is("true"));
assertThat(new StandardJdbcUrlParser().parse("jdbc:tc:postgresql:9.6.8:///demo_ds?TC_TMPFS=/testtmpfs:rw").getQueryProperties().getProperty("TC_TMPFS"), is("/testtmpfs:rw"));
}
}
1 change: 0 additions & 1 deletion infra/database/type/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,5 @@
<module>firebird</module>
<module>h2</module>
<module>sql92</module>
<module>testcontainers</module>
</modules>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,7 @@ public Stream<? extends Arguments> provideArguments(final ExtensionContext exten
Arguments.of("defaultPortAndMicrosoft", "jdbc:microsoft:sqlserver://127.0.0.1;DatabaseName=foo_ds", "127.0.0.1", 1433, "foo_ds", null),
Arguments.of("defaultPortWithoutMicrosoft", "jdbc:sqlserver://127.0.0.1;DatabaseName=foo_ds", "127.0.0.1", 1433, "foo_ds", null),
Arguments.of("databaseNameContainDotAndMicrosoft", "jdbc:microsoft:sqlserver://127.0.0.1:9999;DatabaseName=foo_0.0.0", "127.0.0.1", 9999, "foo_0.0.0", null),
Arguments.of("databaseNameContainDotAndWithoutMicrosoft", "jdbc:sqlserver://127.0.0.1:9999;DatabaseName=foo_0.0.0", "127.0.0.1", 9999, "foo_0.0.0", null),
Arguments.of("testcontainers", "jdbc:tc:sqlserver:2022-CU10-ubuntu-22.04://test-hostname;databaseName=test_database", "test-hostname", 1433, "test_database", null));
Arguments.of("databaseNameContainDotAndWithoutMicrosoft", "jdbc:sqlserver://127.0.0.1:9999;DatabaseName=foo_0.0.0", "127.0.0.1", 9999, "foo_0.0.0", null));
}
}
}
43 changes: 0 additions & 43 deletions infra/database/type/testcontainers/pom.xml

This file was deleted.

Loading