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

Two threading tweaks [JIRA: RIAK-2336] #181

Open
matthewvon opened this issue Dec 24, 2015 · 1 comment
Open

Two threading tweaks [JIRA: RIAK-2336] #181

matthewvon opened this issue Dec 24, 2015 · 1 comment

Comments

@matthewvon
Copy link
Contributor

  1. should create synchronous start-up for thread pool threads like recently done in throttle.cc. The change is not relevant to normal execution. It simply makes unit tests which construct and deconstruct quickly more reliable.
  2. consider using first thread in a pool as replacement for semaphore thread. The semaphore thread is to protect against a race condition where no thread is available as new task arrives, but by the time the new task is on the queue all threads are back to waiting and will never see the task until a second task gets added. Using a conventional mutex and signal only with the first thread will prevent this case AND not heavily burden the system. (Known bad design had one mutex / condition variable for all threads. This was a performance killer.) ... of course performance impact needs to be tested.
@Basho-JIRA Basho-JIRA changed the title Two threading tweaks Two threading tweaks [JIRA: RIAK-2336] Dec 24, 2015
@matthewvon
Copy link
Contributor Author

Item two is complete: branch mv-no-semaphore. Checked into develop July 12, 2016.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants