-
Notifications
You must be signed in to change notification settings - Fork 465
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
catalog: Fix savepoint upper calculation #28360
Conversation
The savepoint catalog mode creates a logical branch of catalog state. Previously, savepoint catalogs would look at the upper of the catalog persist shard to determine the current catalog upper. Looking at the persist shard gives us the upper of the "main" catalog state branch, but not the current savepoint branch upper. Instead, we should be looking at the upper saved in memory. This commit fixes the issue by updating the fetch upper logical and adds some sanity asserts to various related spots in the code. Fixes #28326
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.
Is it possible to write an explicit test for this? I'd sleep better knowing we have both a deterministic and randomized test catching this
Done in the most recent commit. |
The savepoint catalog mode creates a logical branch of catalog state. Previously, savepoint catalogs would look at the upper of the catalog persist shard to determine the current catalog upper. Looking at the persist shard gives us the upper of the "main" catalog state branch, but not the current savepoint branch upper. Instead, we should be looking at the upper saved in memory. This commit fixes the issue by updating the fetch upper logical and adds some sanity asserts to various related spots in the code. Fixes #28326
The savepoint catalog mode creates a logical branch of catalog state. Previously, savepoint catalogs would look at the upper of the catalog persist shard to determine the current catalog upper. Looking at the persist shard gives us the upper of the "main" catalog state branch, but not the current savepoint branch upper. Instead, we should be looking at the upper saved in memory. This commit fixes the issue by updating the fetch upper logical and adds some sanity asserts to various related spots in the code. Fixes #28326
The savepoint catalog mode creates a logical branch of catalog state. Previously, savepoint catalogs would look at the upper of the catalog persist shard to determine the current catalog upper. Looking at the persist shard gives us the upper of the "main" catalog state branch, but not the current savepoint branch upper. Instead, we should be looking at the upper saved in memory.
This commit fixes the issue by updating the fetch upper logical and adds some sanity asserts to various related spots in the code.
Fixes MaterializeInc/database-issues#8298
Motivation
This PR fixes a recognized bug.
Checklist
$T ⇔ Proto$T
mapping (possibly in a backwards-incompatible way), then it is tagged with aT-proto
label.