This PR tries to solve the issue mention in issue #79 and discussion #77 where the database size on disk is overly large due repeated saving the collection causing all of the IO buffers to pile up.
Approach
This PR adds flush and async_flush method to the database struct.
Testing
[x] I have tested this PR locally.
[x] I added tests to cover my changes, if not applicable, I have added a reason why.
Added 2 new tests for both Python and Rust test suites to test the flushes functionalities.
Chore checklist
[ ] I have updated the documentation accordingly.
[ ] I have added comments to most of my code, particularly in hard-to-understand areas.
Purpose
This PR tries to solve the issue mention in issue #79 and discussion #77 where the database size on disk is overly large due repeated saving the collection causing all of the IO buffers to pile up.
Approach
This PR adds
flush
andasync_flush
method to the database struct.Testing
Added 2 new tests for both Python and Rust test suites to test the flushes functionalities.
Chore checklist