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

Add configurable bloom filters #644

Merged
merged 20 commits into from
May 20, 2021
Merged

Conversation

annanay25
Copy link
Contributor

@annanay25 annanay25 commented Apr 12, 2021

Signed-off-by: Annanay [email protected]

What this PR does:
Provides a way to shard out the bloom filter based on the false positive rate and shard size provided.

Which issue(s) this PR fixes:
Fixes #419

Checklist

  • Tests updated
  • NA Documentation added
  • CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]

@annanay25 annanay25 marked this pull request as ready for review May 17, 2021 07:04
@annanay25
Copy link
Contributor Author

annanay25 commented May 17, 2021

something to note - with the following parameters:

bloomFP:          0.05,
shardSize:        250*1024,
estimatedObjects: 10_000_000,

the package creates 244 shards. we'll just have that many bloom files in object storage

Copy link
Member

@joe-elliott joe-elliott left a comment

Choose a reason for hiding this comment

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

Some thoughts.

I didn't dig super hard on the tests, but I think testStreamingBlockToBackendBlock will test that the bloom filters are functioning correctly.

the package creates 244 shards. we'll just have that many bloom files in object storage
Yeah, I think this will be ok :). If not we're about to find out.

Signed-off-by: Annanay <[email protected]>
Copy link
Contributor

@mdisibio mdisibio left a comment

Choose a reason for hiding this comment

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

Nice work, this is much smoother than expected! Left a few comments.

Copy link
Member

@joe-elliott joe-elliott left a comment

Choose a reason for hiding this comment

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

Two final thoughts and then I'm good. @mdisibio anything else?

@mdisibio
Copy link
Contributor

LGTM after reducing maxShardCount.

@annanay25 annanay25 merged commit c61b678 into grafana:main May 20, 2021
@annanay25 annanay25 deleted the cfgble-bloom branch May 20, 2021 16:01
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.

Make Bloom Filter Sharding Configurable
3 participants