This is an automated email from the ASF dual-hosted git repository.
panjuan 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 a737092 Rename DataSourcePropertiesCreator.createDataSource() to
create() (#14790)
a737092 is described below
commit a73709203124030fa9ffa0a834bb2b6b5de1e8e0
Author: Liang Zhang <[email protected]>
AuthorDate: Fri Jan 14 22:58:22 2022 +0800
Rename DataSourcePropertiesCreator.createDataSource() to create() (#14790)
---
.../config/datasource/pool/creator/DataSourcePoolCreatorUtil.java | 2 +-
.../infra/config/datasource/props/DataSourcePropertiesCreator.java | 2 +-
.../config/datasource/props/DataSourcePropertiesCreatorTest.java | 4 ++--
3 files changed, 4 insertions(+), 4 deletions(-)
diff --git
a/shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/config/datasource/pool/creator/DataSourcePoolCreatorUtil.java
b/shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/config/datasource/pool/creator/DataSourcePoolCreatorUtil.java
index 466ce86..862432c 100644
---
a/shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/config/datasource/pool/creator/DataSourcePoolCreatorUtil.java
+++
b/shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/config/datasource/pool/creator/DataSourcePoolCreatorUtil.java
@@ -51,7 +51,7 @@ public final class DataSourcePoolCreatorUtil {
* @return data source properties
*/
public static DataSourceProperties getDataSourceProperties(final
DataSource dataSource) {
- return
DataSourcePropertiesCreator.createDataSourceProperties(dataSource);
+ return DataSourcePropertiesCreator.create(dataSource);
}
/**
diff --git
a/shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/config/datasource/props/DataSourcePropertiesCreator.java
b/shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/config/datasource/props/DataSourcePropertiesCreator.java
index 0921605..b07ece9 100644
---
a/shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/config/datasource/props/DataSourcePropertiesCreator.java
+++
b/shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/config/datasource/props/DataSourcePropertiesCreator.java
@@ -40,7 +40,7 @@ public final class DataSourcePropertiesCreator {
* @param dataSource data source
* @return created data source properties
*/
- public static DataSourceProperties createDataSourceProperties(final
DataSource dataSource) {
+ public static DataSourceProperties create(final DataSource dataSource) {
DataSourceProperties result = new
DataSourceProperties(dataSource.getClass().getName());
result.getProps().putAll(createProperties(dataSource));
return result;
diff --git
a/shardingsphere-infra/shardingsphere-infra-common/src/test/java/org/apache/shardingsphere/infra/config/datasource/props/DataSourcePropertiesCreatorTest.java
b/shardingsphere-infra/shardingsphere-infra-common/src/test/java/org/apache/shardingsphere/infra/config/datasource/props/DataSourcePropertiesCreatorTest.java
index 2f195a7..3e5d652 100644
---
a/shardingsphere-infra/shardingsphere-infra-common/src/test/java/org/apache/shardingsphere/infra/config/datasource/props/DataSourcePropertiesCreatorTest.java
+++
b/shardingsphere-infra/shardingsphere-infra-common/src/test/java/org/apache/shardingsphere/infra/config/datasource/props/DataSourcePropertiesCreatorTest.java
@@ -28,8 +28,8 @@ import static org.junit.Assert.assertThat;
public final class DataSourcePropertiesCreatorTest {
@Test
- public void assertCreateDataSourceProperties() {
-
assertThat(DataSourcePropertiesCreator.createDataSourceProperties(createDataSource()),
is(createDataSourceProperties()));
+ public void assertCreate() {
+ assertThat(DataSourcePropertiesCreator.create(createDataSource()),
is(createDataSourceProperties()));
}
private DataSource createDataSource() {