-
Couldn't load subscription status.
- Fork 4k
changefeedccl: fix test flake by waiting for rangefeed start #152689
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
Conversation
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.
Nice find!
| {`regularUser`, false}, | ||
| {`adminUser`, true}, | ||
| {`viewClusterMetadataUser`, true}, | ||
| {`feedCreator`, false}, |
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.
What's the point of reordering the cases? I ask because changes like this have the cost of adding another commit to the git blame history (for these lines) so there needs to be some kind of benefit that outweighs that
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.
It's possible that the feed creator case was possible not because they lacked the permissions but because no one was able to see the table since the rangefeed hadn't started up yet (this is the reason the admin user case was failing). Putting the true cases before the false cases ensures that the tables are visible to someone when the feed creator can't see them. Do you think it's worth including? I don't feel strongly
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.
IMO it's not really worth switching since with either order, the subtest that would fail would still be adminUser right? We might actually want to randomize the order by using a map instead of a slice so there's more variance, up to you if you want to make that change
Previously, this test would flake because a table that we were asserting the admin user could see hadn't yet become visible. Now we assert the changefeed and rangefeed have started by waiting for a highwater mark. Epic: none Fixes: cockroachdb#152060 Release note: None
eed0d7a to
9f48bed
Compare
|
bors r=andyyang890 |
|
blathers backport 24.3 25.2 25.3 |
|
Based on the specified backports for this PR, I applied new labels to the following linked issue(s). Please adjust the labels as needed to match the branches actually affected by the issue(s), including adding any known older branches. Issue #152060: branch-release-24.3, branch-release-25.2, branch-release-25.3. 🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf. |
Previously, this test would flake because a table that we were asserting the admin user could see hadn't yet become visible. Now we assert the changefeed and rangefeed have started by waiting for a highwater mark.
Epic: none
Fixes: #152060
Release note: None