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

engine: don't create aux dir for read-only engine #41983

Merged
merged 1 commit into from
Oct 29, 2019

Conversation

tbg
Copy link
Member

@tbg tbg commented Oct 29, 2019

It was mildly irritating that

./cockroach debug raft-log not/there 1

would create not/there/auxiliary.

Release note: None

It was mildly irritating that

    ./cockroach debug raft-log not/there 1

would create `not/there/auxiliary`.

Release note: None
@tbg tbg requested a review from petermattis October 29, 2019 14:11
@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Collaborator

@petermattis petermattis 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 notice that we're not creating the auxiliary directory for storage/engine.Pebble. Happy to see that fixed, but also fine if you want to leave that for #storage.

Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @petermattis)

@tbg
Copy link
Member Author

tbg commented Oct 29, 2019

bors r=petermattis

If it's OK with you I'll leave the cleanups to #storage.

craig bot pushed a commit that referenced this pull request Oct 29, 2019
41983: engine: don't create aux dir for read-only engine r=petermattis a=tbg

It was mildly irritating that

    ./cockroach debug raft-log not/there 1

would create `not/there/auxiliary`.

Release note: None

41986: storage: fix stats inconsistency due to WriteTooOld optimization r=irfansharif a=tbg

This fixes a bug introduced in #22315 with the introduction of a "local
retry" to avoid WriteTooOldError inside of 1PC transactions that were
not carrying out any reads. Such a transaction can simply be
re-evaluated at a higher timestamp, which can allow it to commit.

The bug was that when such a re-evaluation was carried out, we were
not discarding the MVCCStats accrued from the first attempt. In
effect, the request would thus be double-counted in stats, which
would set off the consistency checker.

The fix is easy: discard the delta before re-evaluating.

Fixes #31870.

Release note (bug fix): remove a source of (benign) stats
inconsistencies (i.e. the stats of a range not accurately reflecting its
contents).

Co-authored-by: Tobias Schottdorf <[email protected]>
@craig
Copy link
Contributor

craig bot commented Oct 29, 2019

Build succeeded

@craig craig bot merged commit 5ef4362 into cockroachdb:master Oct 29, 2019
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