unb0rk akka-actor-nightly build
This means tightening types from Duration to FiniteDuration in several places; a good thing, since we replace runtime complaints by compile time errors.
This commit is contained in:
parent
4afd41f9c3
commit
251a62293a
34 changed files with 183 additions and 152 deletions
|
|
@ -53,8 +53,8 @@ public class ParentActor extends UntypedActor {
|
|||
//#scatterGatherFirstCompletedRouter
|
||||
ActorRef scatterGatherFirstCompletedRouter = getContext().actorOf(
|
||||
new Props(FibonacciActor.class).withRouter(new ScatterGatherFirstCompletedRouter(5, Duration
|
||||
.parse("2 seconds"))), "router");
|
||||
Timeout timeout = new Timeout(Duration.parse("5 seconds"));
|
||||
.create(2, "seconds"))), "router");
|
||||
Timeout timeout = new Timeout(Duration.create(5, "seconds"));
|
||||
Future<Object> futureResult = akka.pattern.Patterns.ask(scatterGatherFirstCompletedRouter,
|
||||
new FibonacciActor.FibonacciNumber(10), timeout);
|
||||
int result = (Integer) Await.result(futureResult, timeout.duration());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue