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

[IMPROVEMENT] Thread-safe SPDK JSON client #6106

Closed
shuo-wu opened this issue Jun 12, 2023 · 1 comment
Closed

[IMPROVEMENT] Thread-safe SPDK JSON client #6106

shuo-wu opened this issue Jun 12, 2023 · 1 comment
Assignees
Labels
area/v2-data-engine v2 data engine (SPDK) kind/improvement Request for improvement of existing function priority/0 Must be implement or fixed in this release (managed by PO)
Milestone

Comments

@shuo-wu
Copy link
Contributor

shuo-wu commented Jun 12, 2023

Is your improvement request related to a feature? Please describe (👍 if you like this request)

Now the SPDK JSON client is not thread-safe, while the SPDK engine service cannot use a lock to protect it. This leads to some unexpected errors.

Describe the solution you'd like

Make the client thread-safe:

  • Launch a response channel for each call
  • Rely on SPDK request ID to forward the responses to the correct channel the callers are waiting on.

Describe alternatives you've considered

N/A

Additional context

Without this, some features like offline rebuilding are unstable.

@shuo-wu shuo-wu added kind/improvement Request for improvement of existing function area/v2-data-engine v2 data engine (SPDK) labels Jun 12, 2023
@shuo-wu shuo-wu added this to the v1.5.0 milestone Jun 12, 2023
@shuo-wu shuo-wu self-assigned this Jun 12, 2023
@innobead innobead added the priority/2 Nice to implement or fix in this release (managed by PO) label Jun 12, 2023
@shuo-wu shuo-wu changed the title [IMPROVEMENT] Thead-safe SPDK JSON client [IMPROVEMENT] Thread-safe SPDK JSON client Jun 14, 2023
@longhorn-io-github-bot
Copy link

longhorn-io-github-bot commented Jun 15, 2023

Pre Ready-For-Testing Checklist

@innobead innobead modified the milestones: v1.5.0, v1.6.0 Jun 20, 2023
@innobead innobead added priority/0 Must be implement or fixed in this release (managed by PO) and removed priority/2 Nice to implement or fix in this release (managed by PO) labels Jun 20, 2023
@derekbit derekbit moved this to Closed in Longhorn Sprint Aug 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/v2-data-engine v2 data engine (SPDK) kind/improvement Request for improvement of existing function priority/0 Must be implement or fixed in this release (managed by PO)
Projects
Status: Closed
Development

No branches or pull requests

3 participants