-
Notifications
You must be signed in to change notification settings - Fork 156
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
feat: Add Pattern timeout support #1424
base: main
Are you sure you want to change the base?
Conversation
My wife just come to hangzhou, and I may don't have enough time to polish this , any feed back is welcome, I will try to get it done soon. |
Can this wait till 1.1.1 release? |
val p = Promise[T]() | ||
val timeout = using.scheduleOnce(duration) { | ||
p.tryFailure(new TimeoutException(s"Timeout of $duration expired")) | ||
if (future.isInstanceOf[CompletableFuture[T]]) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cool feature, but seem like it doesn't support scala future, because it haven't cancel/interrrupt method
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
that's true.
what is the plan for the shipping of this PR? it looks like it can be help to implement Hedged requests. |
@Roiocam Chinese Spring Festival is coming, I would like to have this done before that. |
Motivation:
refs: #1359
still wip, test is missing