-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Online DDL: publish vreplication_lag_seconds
from vreplication progress
#17263
Conversation
Signed-off-by: Shlomi Noach <[email protected]>
Review ChecklistHello reviewers! 👋 Please follow this checklist when reviewing this Pull Request. General
Tests
Documentation
New flags
If a workflow is added or modified:
Backward compatibility
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #17263 +/- ##
=======================================
Coverage 67.37% 67.37%
=======================================
Files 1573 1573
Lines 253110 253114 +4
=======================================
+ Hits 170535 170547 +12
+ Misses 82575 82567 -8 ☔ View full report in Codecov by Sentry. 🚨 Try these New Features:
|
// Still copying | ||
return false, nil | ||
} | ||
// copy_state must have no entries for this vreplication id: if entries are |
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.
Maybe in a future refactor, similar to the extraction into Lag()
, you could extract the code to check if copy is in progress too into a utility function ...
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.
Good idea. To do that I'd need to issue a query against copy_state
. Or I can converge the two queries (vreplication
+copy_state
into one. I guess that would be wasteful for most of the time though.
Description
A new column in
schema_migrations
:vreplication_lag_seconds
publishes thevreplication
(rather,vplayer
) lag on a vreplication migration. This is computed by the higher difference of vreplication's time updted and transaction timestamp compared with time now.This just adds more visibility into the underlying workflow.
Related Issue(s)
#17264
Checklist
Deployment Notes