nsivabalan commented on code in PR #20429:
URL: https://github.com/apache/hudi/pull/20429#discussion_r4452557806
##########
hudi-utilities/src/main/java/org/apache/hudi/utilities/streamer/StreamSync.java:
##########
@@ -1247,13 +1247,18 @@ private void reInitWriteClient(HoodieSchema
sourceSchema, HoodieSchema targetSch
}
}
- if (writeClient != null) {
- // Close Write client.
- writeClient.close();
- }
KeyGenUtils.recordComplexKeygenEncodingIfMissing(metaClient, writeConfig);
+ SparkRDDWriteClient previousWriteClient = writeClient;
writeClient = new SparkRDDWriteClient<>(hoodieSparkContext, writeConfig,
embeddedTimelineService);
- onInitializingHoodieWriteClient.apply(writeClient);
+ // Switch the async table services before closing the previous client.
Each handoff waits for any active run
Review Comment:
Good catch, thanks. You are right: since #20444 the switch no longer waits
for an active run. Fixed the comment in 4de97394. It now says new runs use the
new client, a run still on the previous client may fail once it is closed, and
that failure stops ingestion with its cause. The PR description is updated to
match.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]