Skip to content

storage: don't crash when applying side-effects of old ChangeReplicas trigger#41171

Merged
craig[bot] merged 1 commit intocockroachdb:masterfrom
nvb:nvanbenschoten/changeReplSM2
Sep 27, 2019
Merged

storage: don't crash when applying side-effects of old ChangeReplicas trigger#41171
craig[bot] merged 1 commit intocockroachdb:masterfrom
nvb:nvanbenschoten/changeReplSM2

Conversation

@nvb
Copy link
Copy Markdown
Contributor

@nvb nvb commented Sep 27, 2019

Fixes #41155.
Fixes #41147.

The fix in #41148 avoided a crash when staging a ChangeReplicas trigger with
a DeprecatedNextReplicaID in an application batch, but there was another bug
where applying the side-effects of such a command still caused a crash. This
commit fixes the crash and extends the test added in #41148 to go through the
whole process of applying the command (which would have caught the second
crash as well).

Release justification: fixes a crash in mixed version clusters.

Release note: None

… trigger

Fixes cockroachdb#41155.

The fix in cockroachdb#41148 avoided a crash when staging a ChangeReplicas trigger with
a DeprecatedNextReplicaID in an application batch, but there was another bug
where applying the side-effects of such a command still caused a crash. This
commit fixes the crash and extends the test added in cockroachdb#41148 to go through the
whole process of applying the command (which would have caught the second
crash as well).

Release justification: fixes a crash in mixed version clusters.

Release note: None
@nvb nvb requested a review from ajwerner September 27, 2019 19:42
@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

@nvb
Copy link
Copy Markdown
Contributor Author

nvb commented Sep 27, 2019

I'm running this with version/mixed/nodes=5 now to double-check that there aren't any more of these issues.

Copy link
Copy Markdown
Contributor

@ajwerner ajwerner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

I appreciate your jumping on this.

Reviewed 4 of 4 files at r1.
Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained

@nvb
Copy link
Copy Markdown
Contributor Author

nvb commented Sep 27, 2019

No problem, I should have found this yesterday. I was searching for DeprecatedNextReplicaID when really I should have been looking for its absence.

@nvb
Copy link
Copy Markdown
Contributor Author

nvb commented Sep 27, 2019

version/mixed/nodes=5 hasn't finished yet, but it's been running for about an hour without issue. I expect it to pass and will dig into if it doesn't.

bors r+

@craig
Copy link
Copy Markdown
Contributor

craig bot commented Sep 27, 2019

Build failed

@nvb
Copy link
Copy Markdown
Contributor Author

nvb commented Sep 27, 2019

Examples-ORMs wasn't happy there.

bors r+

craig bot pushed a commit that referenced this pull request Sep 27, 2019
41171: storage: don't crash when applying side-effects of old ChangeReplicas trigger r=nvanbenschoten a=nvanbenschoten

Fixes #41155.
Fixes #41147.

The fix in #41148 avoided a crash when staging a ChangeReplicas trigger with
a DeprecatedNextReplicaID in an application batch, but there was another bug
where applying the side-effects of such a command still caused a crash. This
commit fixes the crash and extends the test added in #41148 to go through the
whole process of applying the command (which would have caught the second
crash as well).

Release justification: fixes a crash in mixed version clusters.

Release note: None

Co-authored-by: Nathan VanBenschoten <nvanbenschoten@gmail.com>
@craig
Copy link
Copy Markdown
Contributor

craig bot commented Sep 27, 2019

Build succeeded

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.

roachtest: version/mixed/nodes=5 failed roachtest: tpcc/mixed-headroom/n5cpu16 failed

3 participants