-
Notifications
You must be signed in to change notification settings - Fork 584
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Minor cleanup in preparation of making socket checkouts along non-blo…
…cking code paths asynchronous. src/java/voldemort/store/nonblockingstore/ThreadPoolBasedNonblockingStoreImpl.java - fix missing ns to ms conversion src/java/voldemort/store/socket/clientrequest/ClientRequestExecutor.java src/java/voldemort/store/socket/clientrequest/ClientRequestExecutorFactory.java - remove unnecessary selectionKey from checkTimeout interface src/java/voldemort/utils/pool/KeyedResourcePool.java - removed extraneous maxCreateAttempts - attemptGrow returns true if pool grew - refactored checkoutOrCreateResource - renamed to attemptCheckout - attemptCheckout is non blocking - attemptCheckout does not check timeouts - refactored checkout - removed unreachable code (only one attempt could ever be made so attempts and maxCreateAttempts are extraneous. - made it clearer that exceptions control flow through try block * even though code looks a lot different, I believe exact functionality is preserved except for one thing: the possibility of a single additional non-blocking get on the pool (resources) when attemptGrow returns true.
- Loading branch information
Showing
4 changed files
with
37 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters