Skip to content

changefeedccl: fix flakey tests#92341

Merged
craig[bot] merged 1 commit intocockroachdb:masterfrom
HonoreDB:fix_only_initial_scan_races
Nov 30, 2022
Merged

changefeedccl: fix flakey tests#92341
craig[bot] merged 1 commit intocockroachdb:masterfrom
HonoreDB:fix_only_initial_scan_races

Conversation

@HonoreDB
Copy link
Copy Markdown
Contributor

@HonoreDB HonoreDB commented Nov 22, 2022

Our test SQL connection doesn't always read its own writes: it can use different connections for different queries. So

INSERT INTO foo;
feed(CREATE CHANGEFEED FOR foo)

is a race condition. This just doesn't matter for most tests because if the insert happens after the initial scan, it creates the same payload. But tests with initial_scan='only' won't see it at all.

Fixes #92211

Release note: None

@HonoreDB HonoreDB requested a review from a team as a code owner November 22, 2022 19:04
@HonoreDB HonoreDB requested review from shermanCRL and removed request for a team November 22, 2022 19:04
@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

Our test SQL connection doesn't always read its own writes:
it can use different connections for different queries.
So
```
INSERT INTO foo;
feed(CREATE CHANGEFEED FOR foo)
```
is a race condition. This just doesn't matter for most tests
because if the insert happens after the initial scan, it creates
the same payload. But tests with initial_scan='only' won't see it
at all.

Fixes cockroachdb#92211

Release note: None
@HonoreDB HonoreDB force-pushed the fix_only_initial_scan_races branch from f6c6e37 to c6d4a27 Compare November 23, 2022 15:07
@HonoreDB
Copy link
Copy Markdown
Contributor Author

bors r=[miretskiy]

@craig
Copy link
Copy Markdown
Contributor

craig bot commented Nov 29, 2022

Build failed (retrying...):

@craig
Copy link
Copy Markdown
Contributor

craig bot commented Nov 30, 2022

Build succeeded:

@craig craig bot merged commit b21fd88 into cockroachdb:master Nov 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ccl/changefeedccl: TestChangefeedOnlyInitialScan failed

3 participants