This is an automated email from the ASF dual-hosted git repository.
sunxiaojian pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/rocketmq-connect.git
The following commit(s) were added to refs/heads/master by this push:
new b0624d57 Revert "[ISSUE #424] Adjust the order in which
WorkerSourceTask topics are acquired (#426)" (#429)
b0624d57 is described below
commit b0624d5751c23af24dcc489fdc4f4ab48193e26b
Author: zhoubo <[email protected]>
AuthorDate: Wed Feb 22 11:01:18 2023 +0800
Revert "[ISSUE #424] Adjust the order in which WorkerSourceTask topics are
acquired (#426)" (#429)
This reverts commit d52a79d3e6e119151e4c8e38a08ce75ebb6821df.
---
.../connect/runtime/connectorwrapper/WorkerSourceTask.java | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git
a/rocketmq-connect-runtime/src/main/java/org/apache/rocketmq/connect/runtime/connectorwrapper/WorkerSourceTask.java
b/rocketmq-connect-runtime/src/main/java/org/apache/rocketmq/connect/runtime/connectorwrapper/WorkerSourceTask.java
index ec94b8e3..f379b7fb 100644
---
a/rocketmq-connect-runtime/src/main/java/org/apache/rocketmq/connect/runtime/connectorwrapper/WorkerSourceTask.java
+++
b/rocketmq-connect-runtime/src/main/java/org/apache/rocketmq/connect/runtime/connectorwrapper/WorkerSourceTask.java
@@ -420,11 +420,10 @@ public class WorkerSourceTask extends WorkerTask {
* @return
*/
private String maybeCreateAndGetTopic(ConnectRecord record) {
- // topic from config
- String topic =
taskConfig.getString(SourceConnectorConfig.CONNECT_TOPICNAME);
+ String topic = overwriteTopicFromRecord(record);
if (StringUtils.isBlank(topic)) {
- // try topic from config
- topic = overwriteTopicFromRecord(record);
+ // topic from config
+ topic =
taskConfig.getString(SourceConnectorConfig.CONNECT_TOPICNAME);
}
if (StringUtils.isBlank(topic)) {
throw new ConnectException("source connect lack of topic config");