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 alternative getStatus() method to OperationFuture that takes time expiration parameters #22

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ryan-mccaffrey
Copy link

@ryan-mccaffrey ryan-mccaffrey commented Aug 7, 2017

Adds a method for getStatus() that takes expiration duration and TimeUnit parameters to be used with the the parametrized version of get().

Currently the only implementation of getStatus() takes no parameters, and uses the default timeout duration when getting the OperationStatus of the operation. I found it useful to create a method that takes long duration and TimeUnit units parameters to allow the client to specify timeout, as is already supported by the method get(long duration, TimeUnit units).

@daschl

Adds a method for `getStatus()` that takes expiration duration and TimeUnit parameters to be used with the the parametrized version of `get()`.
@ryan-mccaffrey ryan-mccaffrey changed the title Update OperationFuture.java Add alternative getStatus() method to OperationFuture that takes time expiration parameters Aug 7, 2017
@ryan-mccaffrey ryan-mccaffrey changed the title Add alternative getStatus() method to OperationFuture that takes time expiration parameters Add alternative getStatus() method to OperationFuture that takes time expiration parameters Aug 7, 2017
@ingenthr ingenthr self-assigned this Apr 2, 2018
@ingenthr
Copy link

ingenthr commented Apr 2, 2018

Review is up at http://review.couchbase.org/#/c/91951/ - unfortunately, this doesn't compile.

public OperationStatus getStatus(long duration, TimeUnit units) {
if (status == null) {
try {
get(duration, units);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fails to compile on this line. See http://review.couchbase.org/#/c/91951/

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

Successfully merging this pull request may close these issues.

2 participants