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

storage: remove SingleDel invariant cluster settings #138541

Merged
merged 2 commits into from
Jan 8, 2025

Conversation

RaduBerinde
Copy link
Member

go.mod: bump Pebble to d21c9e72493f

Changes:

  • d21c9e72 db: add PossibleAPIMisuseEvent
  • e2d1b6cf cockroachkvs: add FormatKey, ParseFormattedKey

Release note: none.
Epic: none.

storage: remove SingleDel invariant cluster settings

Also refactor SingleDel invariant callbacks to use the new event.

Epic: none
Release note: None

Changes:

 * [`d21c9e72`](cockroachdb/pebble@d21c9e72) db: add PossibleAPIMisuseEvent
 * [`e2d1b6cf`](cockroachdb/pebble@e2d1b6cf) cockroachkvs: add FormatKey, ParseFormattedKey

Release note: none.
Epic: none.
@RaduBerinde RaduBerinde requested review from a team as code owners January 7, 2025 20:26
Copy link

blathers-crl bot commented Jan 7, 2025

It looks like your PR touches production code but doesn't add or edit any test code. Did you consider adding tests to your PR?

🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf.

@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Collaborator

@jbowens jbowens left a comment

Choose a reason for hiding this comment

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

Thought of another instance where we could use this new misuse API event and filed cockroachdb/pebble#4234

:lgtm:

Reviewed 4 of 4 files at r1, 2 of 2 files at r2, all commit messages.
Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @sumeerbhola)

Copy link
Member Author

@RaduBerinde RaduBerinde left a comment

Choose a reason for hiding this comment

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

TFTR! Good idea!

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

Copy link
Member Author

@RaduBerinde RaduBerinde left a comment

Choose a reason for hiding this comment

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

bors r+

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

Copy link
Collaborator

@sumeerbhola sumeerbhola left a comment

Choose a reason for hiding this comment

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

Reviewed 2 of 2 files at r2, all commit messages.
Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @RaduBerinde)


pkg/storage/pebble.go line 1547 at r2 (raw file):

					log.Infof(p.logCtx, "possible ineffectual SingleDel on key %s", roachpb.Key(info.UserKey))
				}
				atomic.AddInt64(&p.singleDelInvariantViolationCount, 1)

shouldn't this increment p.singleDelIneffectualCount, in that the increments here and below have been swapped.

@RaduBerinde
Copy link
Member Author

bors r-

Also refactor SingleDel invariant callbacks to use the new event.

Epic: none
Release note: None
Copy link
Member Author

@RaduBerinde RaduBerinde left a comment

Choose a reason for hiding this comment

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

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


pkg/storage/pebble.go line 1547 at r2 (raw file):

Previously, sumeerbhola wrote…

shouldn't this increment p.singleDelIneffectualCount, in that the increments here and below have been swapped.

Good catch, fixed. Thanks!!

Copy link
Collaborator

@sumeerbhola sumeerbhola left a comment

Choose a reason for hiding this comment

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

:lgtm:

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

@RaduBerinde
Copy link
Member Author

bors r+

@craig craig bot merged commit d793f52 into cockroachdb:master Jan 8, 2025
22 checks passed
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.

4 participants