-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Re-sync in case of stale offset #48578
Re-sync in case of stale offset #48578
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 1 Skipped Deployment
|
when (streamFeedBootstrap.currentState?.isEmpty) { | ||
false -> streamFeedBootstrap.currentState!! | ||
else -> return coldStart(streamState) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This fixes a bug:
When sync that includes a number of feeds with some that haven't started yet, during checkpoint those feeds will have a stream state of {}
.
Stopping and restarting the sync need to treat them as a cold start. before this fix those {}
feeds didn't do a snapshot.
While verifying this pr I noticed another bug that is not directly related to resync but has to do with how empty tables save their state.
Issue fixed in #48593 branched out of this PR. |
if (CDCNeedsRestart) { | ||
globalLockResource.markCdcAsComplete() | ||
throw TransientErrorException( | ||
"Saved offset no longer present on the server, Airbyte is going to trigger a sync from scratch." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: "presents"
What
With this change mysql will now correctly do a re-sync in case a saved CDC offset is found to be stale, and mysql is configured to go to resync rather than fail.
How
CDCPartitionsCreator goes into the following flow:
Review guide