Skip to content
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

backport-2.0: distsql: consult liveness during physical planning #23916

Merged
merged 1 commit into from
Apr 6, 2018

Conversation

tbg
Copy link
Member

@tbg tbg commented Mar 15, 2018

Backport 1/1 commits from #23834.

/cc @cockroachdb/release


The recent PR #22658 introduced a regression in
(*rpcContext).ConnHealth which caused DistSQL to continue planning on
unavailable nodes for about an hour (ttlNodeDescriptorGossip) if the
leaseholder cache happened to not be updated by other non-DistSQL
requests.

Instead, consult node liveness and avoid planning on dead nodes. This
reduces the problem to a <10s window. The defunct ConnHealth mechanism
still protects against planning in some of cases (supposedly due to a
once-per-second reconnection policy) and is retained for that reason,
with issue #23829 filed to decide its future.

NB: I'm not putting a release note since this was introduced after 1.1.
We released it in a beta, though, so it may be worth calling out there.

Touches #23601. (Not fixing it because this issue should only close
when there's a roachtest).

Release note (bug fix): NB: this fixes a regression introduced in
2.0-beta, and not present in 1.1: Avoid planning DistSQL errors against
unavailable nodes.

@tbg tbg requested review from a team March 15, 2018 18:28
The recent PR cockroachdb#22658 introduced a regression in
`(*rpcContext).ConnHealth` which caused DistSQL to continue planning on
unavailable nodes for about an hour (`ttlNodeDescriptorGossip`) if the
leaseholder cache happened to not be updated by other non-DistSQL
requests.

Instead, consult node liveness and avoid planning on dead nodes. This
reduces the problem to a <10s window. The defunct `ConnHealth` mechanism
still protects against planning in some of cases (supposedly due to a
once-per-second reconnection policy) and is retained for that reason,
with issue cockroachdb#23829 filed to decide its future.

NB: I'm not putting a release note since this was introduced after 1.1.
We released it in a beta, though, so it may be worth calling out there.

Touches cockroachdb#23601. (Not fixing it because this issue should only close
when there's a roachtest).

Release note (bug fix): NB: this fixes a regression introduced in
2.0-beta, and not present in 1.1: Avoid planning DistSQL errors against
unavailable nodes.
@cockroach-teamcity
Copy link
Member

This change is Reviewable

@tbg
Copy link
Member Author

tbg commented Apr 5, 2018

Hmm, I missed that this didn't get reviewed and/or merged. Should definitely get this into 2.0.1. Ping @bdarnell

@tbg tbg requested a review from bdarnell April 5, 2018 23:50
@tbg
Copy link
Member Author

tbg commented Apr 5, 2018

bors try

craig bot added a commit that referenced this pull request Apr 5, 2018
@andreimatei
Copy link
Contributor

:lgtm:


Review status: 0 of 4 files reviewed at latest revision, all discussions resolved, all commit checks successful.


Comments from Reviewable

@craig
Copy link
Contributor

craig bot commented Apr 6, 2018

try

Build succeeded

@tbg
Copy link
Member Author

tbg commented Apr 6, 2018

Thanks @andreimatei!

bors r+

craig bot added a commit that referenced this pull request Apr 6, 2018
23916: backport-2.0: distsql: consult liveness during physical planning r=tschottdorf a=tschottdorf

Backport 1/1 commits from #23834.

/cc @cockroachdb/release

---

The recent PR #22658 introduced a regression in
`(*rpcContext).ConnHealth` which caused DistSQL to continue planning on
unavailable nodes for about an hour (`ttlNodeDescriptorGossip`) if the
leaseholder cache happened to not be updated by other non-DistSQL
requests.

Instead, consult node liveness and avoid planning on dead nodes. This
reduces the problem to a <10s window. The defunct `ConnHealth` mechanism
still protects against planning in some of cases (supposedly due to a
once-per-second reconnection policy) and is retained for that reason,
with issue #23829 filed to decide its future.

NB: I'm not putting a release note since this was introduced after 1.1.
We released it in a beta, though, so it may be worth calling out there.

Touches #23601. (Not fixing it because this issue should only close
when there's a roachtest).

Release note (bug fix): NB: this fixes a regression introduced in
2.0-beta, and not present in 1.1: Avoid planning DistSQL errors against
unavailable nodes.
@craig
Copy link
Contributor

craig bot commented Apr 6, 2018

Build succeeded

@craig craig bot merged commit 93a7164 into cockroachdb:release-2.0 Apr 6, 2018
@tbg tbg deleted the backport2.0-23834 branch May 8, 2018 15:04
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.

3 participants