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 RID reservation infrastructure #45064

Closed
wants to merge 3 commits into from

Conversation

RandomShaper
Copy link
Member

@RandomShaper RandomShaper commented Jan 10, 2021

The goal is avoiding syncs in the multi-threaded servers when an item is created.

  • Before this PR, a create command sent to a server via the MT queue needs to be executed so the call can return the created RID to the caller, which involves running every command in the queue (sync).
  • After this PR, the caller gets an RID immediately (because it's just "reserved"), but the actual creation, which needs everything in the queue up to that point to have been processed, is put in the queue so it can be run when it's time, without having to sync.

This also removes the need of RID pooling, which was the former mechanism used to prevent syncs, less efficient than the current one.

The idea about separating allocation from initialization is @reduz's. This is the implementation I've been able to come up with.

@RandomShaper RandomShaper added this to the 4.0 milestone Jan 10, 2021
@RandomShaper RandomShaper force-pushed the lazy_rid branch 2 times, most recently from dbe6b24 to 3a57b90 Compare January 10, 2021 06:20
@Calinou

This comment has been minimized.

@RandomShaper RandomShaper force-pushed the lazy_rid branch 2 times, most recently from eb4b7d5 to 1f23c77 Compare January 10, 2021 14:36
@RandomShaper

This comment has been minimized.

@RandomShaper
Copy link
Member Author

Superseded by #45852.

@RandomShaper RandomShaper deleted the lazy_rid branch February 10, 2021 19:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants