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

[DocDB] Table Locks: TSLocalLockManager at master #24005

Closed
1 task done
amitanandaiyer opened this issue Sep 18, 2024 · 0 comments
Closed
1 task done

[DocDB] Table Locks: TSLocalLockManager at master #24005

amitanandaiyer opened this issue Sep 18, 2024 · 0 comments
Assignees
Labels
area/docdb YugabyteDB core features kind/enhancement This is an enhancement of an existing feature priority/medium Medium priority issue

Comments

@amitanandaiyer
Copy link
Contributor

amitanandaiyer commented Sep 18, 2024

Jira Link: DB-12893

Description

Add TSLocalLockManager to the ObjectLockInfoManager at master.

This allows master to check and detect DDL lock requests that may end up blocking on other DDL requests.

Any request which is accepted by Master's local lock manager, can be immediately persisted, even before forwarding the lock requests to all the TServers. This simplifies the bootstrap process of new TServers, as they do not have to worry about any in-progress requests. -- any inprogress request would have already persisted it's state at the master, and been included in the bootstrap.

One con of this approach is that -- until we implement wait-queues/async queues -- waiting for the lock may involve blocking an RPC thread. This should be few in number as we do not expect to have too many DDL requests.

Issue Type

kind/enhancement

Warning: Please confirm that this issue does not contain any sensitive information

  • I confirm this issue does not contain any sensitive information.
@amitanandaiyer amitanandaiyer added area/docdb YugabyteDB core features status/awaiting-triage Issue awaiting triage labels Sep 18, 2024
@amitanandaiyer amitanandaiyer self-assigned this Sep 18, 2024
@yugabyte-ci yugabyte-ci added kind/enhancement This is an enhancement of an existing feature priority/medium Medium priority issue labels Sep 18, 2024
@rthallamko3 rthallamko3 removed the status/awaiting-triage Issue awaiting triage label Oct 14, 2024
amitanandaiyer added a commit that referenced this issue Oct 24, 2024
Summary:
This diff adds a TSLocalLockManager to the ObjectLockInfoManager at master.
This allows master to check and detect DDL lock requests that may end up blocking on other DDL requests.

Any request which is accepted by Master's local lock manager, can be immediately persisted, even before forwarding the lock requests to all the TServers. This simplifies the bootstrap process of new TServers, as they do not have to worry about any in-progress requests. -- any inprogress request would have already persisted it's state at the master, and been included in the bootstrap.

One con of this approach is that -- until we implement wait-queues/async queues -- waiting for the lock may involve blocking an RPC thread. This should be few in number as we do not expect to have too many DDL requests.
Jira: DB-12893

Test Plan: ybd --cxx-test object_lock-test

Reviewers: bkolagani, zdrudi

Reviewed By: zdrudi

Subscribers: ybase

Differential Revision: https://phorge.dev.yugabyte.com/D38167
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/docdb YugabyteDB core features kind/enhancement This is an enhancement of an existing feature priority/medium Medium priority issue
Projects
None yet
Development

No branches or pull requests

3 participants