yashmayya commented on code in PR #13750:
URL: https://github.com/apache/kafka/pull/13750#discussion_r1216967433


##########
connect/runtime/src/main/java/org/apache/kafka/connect/runtime/distributed/DistributedHerder.java:
##########
@@ -1104,7 +1104,9 @@ public void stopConnector(final String connName, final 
Callback<Void> callback)
                     writeTaskConfigs(connName, Collections.emptyList());
                     configBackingStore.putTargetState(connName, 
TargetState.STOPPED);
                     // Force a read of the new target state for the connector
-                    refreshConfigSnapshot(workerSyncTimeoutMs);
+                    if (!refreshConfigSnapshot(workerSyncTimeoutMs)) {
+                        throw new ConnectException("Failed to read to end of 
config topic");

Review Comment:
   Yeah, that does seem to make sense. So, for the stopped state for instance, 
we'd refresh the config topic view before writing task configs (to ensure that 
the connector isn't in a stopped state) or resetting connector offsets instead 
of doing so after writing the stopped target state itself?



-- 
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: jira-unsubscr...@kafka.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to