You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2022/08/16 04:29:55 UTC
[GitHub] [shardingsphere] huangdx0726 commented on a diff in pull request #20207: Decouple PipelineDDLGenerator with ContextManager for common usage
huangdx0726 commented on code in PR #20207:
URL: https://github.com/apache/shardingsphere/pull/20207#discussion_r946325849
##########
shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-core/src/main/java/org/apache/shardingsphere/data/pipeline/core/metadata/generator/PipelineDDLGenerator.java:
##########
@@ -67,27 +65,31 @@ public final class PipelineDDLGenerator {
private static final String DELIMITER = ";";
private static final String SET_SEARCH_PATH_PREFIX = "set search_path";
-
- private final ContextManager contextManager;
-
+
/**
* Generate logic ddl sql.
*
- * @param databaseType database type
+ * @param dataSource data source
* @param databaseName database name
* @param schemaName schema name
- * @param tableName table name
+ * @param logicTableName table name
+ * @param actualTableName actual table name
+ * @param databases databases
+ * @param parserEngine parser engine
* @return ddl SQL
*/
@SneakyThrows
- public String generateLogicDDLSQL(final DatabaseType databaseType, final String databaseName, final String schemaName, final String tableName) {
- ShardingSphereDatabase database = contextManager.getMetaDataContexts().getMetaData().getDatabase(databaseName);
+ public String generateLogicDDLSQL(final DataSource dataSource, final String databaseName, final String schemaName,
+ final String logicTableName, final String actualTableName,
+ final Map<String, ShardingSphereDatabase> databases, final ShardingSphereSQLParserEngine parserEngine) {
Review Comment:
I’ll fix it
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org