update comments to correctly reflect counter space usage#189
Merged
karlmcguire merged 1 commit intodgraph-io:masterfrom Apr 14, 2021
Merged
update comments to correctly reflect counter space usage#189karlmcguire merged 1 commit intodgraph-io:masterfrom
karlmcguire merged 1 commit intodgraph-io:masterfrom
Conversation
Contributor
Author
|
Hi - any feedback on this? I'd love to move it out of my PR inbox (or make changes as needed)! Let me know 😄 |
Contributor
Author
|
@manishrjain @karlmcguire Would it be possible to get a review on this? This caused some confusion for us when rolling out a ristretto cache in production, and it would be nice to avoid this confusion for future users! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When using ristretto in our application, we noticed that the memory used per counter was much higher than the documentation suggested. This PR updates the comments in the config struct to accurately represent the space per counter (and matches our observations).
Sources:
https://github.com/neena/ristretto/blob/29b4dd7a077785696ba5422081b3c301d4c1e5f1/sketch.go#L43-L62
https://github.com/neena/ristretto/blob/8f368f2f2ab3a54cbe62fb9772cd75ce55e07802/z/bbloom.go#L51-L75
This change is