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

Bloom filter #438

Merged
merged 31 commits into from
Aug 17, 2024
Merged

Bloom filter #438

merged 31 commits into from
Aug 17, 2024

Conversation

jmalkin
Copy link
Contributor

@jmalkin jmalkin commented Aug 13, 2024

I think this is a complete filter, including compatibility tests iwht java (that are not yet implemented in java!).

I'm look for feedback on how I handled wrapping. It feels a little too parallel to java in some ways, with wrap() vs writable_wrap(), which I'm not sure is a good idea. The other issue is taht the former returns a const sketch, but counting the number of bits set may require modifying the filter. It should compute the number if it's in read-only mode so I could potentially add a const version of that method -- or just make it not update the internal state.

Anyway, I'm fairly sure there are missed const values and other changes needed. But feel free to start with big picture design first and then move to details once we're happy with the overall structure.

@coveralls
Copy link

coveralls commented Aug 14, 2024

Pull Request Test Coverage Report for Build 10429686471

Details

  • 451 of 499 (90.38%) changed or added relevant lines in 4 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.3%) to 98.713%

Changes Missing Coverage Covered Lines Changed/Added Lines %
filters/include/bloom_filter_builder_impl.hpp 41 43 95.35%
filters/include/bloom_filter_impl.hpp 317 332 95.48%
common/include/xxhash64.h 44 75 58.67%
Totals Coverage Status
Change from base Build 10149063070: -0.3%
Covered Lines: 16880
Relevant Lines: 17100

💛 - Coveralls

@jmalkin
Copy link
Contributor Author

jmalkin commented Aug 16, 2024

I think I have addressed all the comments now


// forward declarations
template<typename A> class bloom_filter_alloc;
template<typename A> class bloom_filter_builder_alloc;
Copy link
Contributor

Choose a reason for hiding this comment

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

do we still need this one?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We do not. Removed, and will wait for tests to pass before merging,

@jmalkin jmalkin merged commit 4e4a944 into apache:master Aug 17, 2024
5 checks passed
@jmalkin jmalkin deleted the bloom branch August 17, 2024 05:12
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