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

Multiple inserts in a row are slow because of the snapshotting #144

Open
dumbbell opened this issue Oct 3, 2022 · 0 comments
Open

Multiple inserts in a row are slow because of the snapshotting #144

dumbbell opened this issue Oct 3, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@dumbbell
Copy link
Member

dumbbell commented Oct 3, 2022

When we import definitions in RabbitMQ, we perform many #put{} in a row. Currently, Khepri's state machine asks Ra to take a snapshot every 4096 commands. With a large definitions import, this causes a lot of snapshotting.

The first suggestion from @kjnilsson was to skip snapshotting when inserting new tree nodes. Indeed, attempting a snapshot after this won't free anything: new tree nodes inserted don't replace other tree nodes. Therefore, if we don't count new tree nodes in the threshold towards the next snapshot, we might save time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant