From 36cf41fa34ca109e15df81ac41cee4b547cc995c Mon Sep 17 00:00:00 2001 From: mozhenghua Date: Fri, 10 Mar 2023 15:26:51 +0800 Subject: [PATCH] upline the dataSourceFactoryGetter pos --- .../alibaba/datax/plugin/rdbms/writer/CommonRdbmsWriter.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugin-rdbms-util/src/main/java/com/alibaba/datax/plugin/rdbms/writer/CommonRdbmsWriter.java b/plugin-rdbms-util/src/main/java/com/alibaba/datax/plugin/rdbms/writer/CommonRdbmsWriter.java index c2d616c353..dc5353f7e9 100755 --- a/plugin-rdbms-util/src/main/java/com/alibaba/datax/plugin/rdbms/writer/CommonRdbmsWriter.java +++ b/plugin-rdbms-util/src/main/java/com/alibaba/datax/plugin/rdbms/writer/CommonRdbmsWriter.java @@ -241,7 +241,7 @@ public void init(Configuration writerSliceConfig) { this.jdbcUrl = ss[2]; LOG.info("this is ob1_0 jdbc url. user=" + this.username + " :url=" + this.jdbcUrl); } - + this.dataSourceFactoryGetter = DBUtil.getWriterDataSourceFactoryGetter(writerSliceConfig, this.containerContext); this.table = SelectTable.createInTask(writerSliceConfig, this.dataSourceFactoryGetter.getDBReservedKeys()); @@ -256,7 +256,7 @@ public void init(Configuration writerSliceConfig) { this.writeRecordSql = String.format(INSERT_OR_REPLACE_TEMPLATE, this.table); BASIC_MESSAGE = String.format("jdbcUrl:[%s], table:[%s]", this.jdbcUrl, this.table); - this.dataSourceFactoryGetter = DBUtil.getWriterDataSourceFactoryGetter(writerSliceConfig, this.containerContext); + this.columns = SelectCols.createSelectCols(writerSliceConfig, this.dataSourceFactoryGetter.getDataSourceFactory()); this.columnNumber = this.columns.size(); }