valkey-bloom
valkey-bloom copied to clipboard
Fix AOF rewrite and restore BF tests
The AOF rewrite tests were failing because bloom filter data was not being properly restored after server restart. The root cause was twofold:
- BF.LOAD command was replicating during AOF loading, causing duplicate entries
- Tests were not properly configuring AOF persistence for server restart
Changes:
- Modified BF.LOAD handler to skip replication when loading from AOF by checking must_obey_client() context
- Updated AOF tests to enable appendonly before adding data
- Added wait for initial AOF rewrite to prevent concurrent rewrites
- Set appendonly in server startup args for proper AOF loading on restart
Also includes minor fixes:
- Changed build.sh shebang to bash for better compatibility
- Updated pytest requirement to 7.4.3
- Fixed indentation in utils.rs documentation
Fixes #74
@arpitbbhayani can you fix the DCO?
Thank you so much for reviewing the code. Apologies that it took some time for me to come back. I have addressed all the concerns and made the changes.
Now, the PR only fixes the AOF tests that were failing and other changes have been reverted.