@Override protected void onActorStarting() { final ActorFuture<ServerInputSubscription> openFuture = serverTransport.openSubscription("subscriptionRequestHandler", messageHandler, null); actor.runOnCompletion( openFuture, (subscription, throwable) -> { if (throwable != null) { throw new RuntimeException(throwable); } else { actor.consume( subscription, () -> { if (subscription.poll() == 0) { actor.yield(); } }); } }); }
@Override protected void onActorStarting() { final ActorFuture<ServerInputSubscription> openFuture = serverTransport.openSubscription("subscriptionRequestHandler", messageHandler, null); actor.runOnCompletion( openFuture, (subscription, throwable) -> { if (throwable != null) { throw new RuntimeException(throwable); } else { actor.consume( subscription, () -> { if (subscription.poll() == 0) { actor.yield(); } }); } }); }
@Override protected void onActorStarting() { pushDeploymentRequestHandler = new PushDeploymentRequestHandler(leaderForPartitions, actor); final ActorFuture<ServerInputSubscription> subscriptionFuture = serverTransport.openSubscription("leader-management-request-handler", this, this); actor.runOnCompletion( subscriptionFuture, (subscription, err) -> { if (err != null) { throw new RuntimeException(err); } else { actor.consume( subscription, () -> { if (subscription.poll() == 0) { actor.yield(); } }); } }); }
@Override protected void onActorStarting() { pushDeploymentRequestHandler = new PushDeploymentRequestHandler(leaderForPartitions, actor); final ActorFuture<ServerInputSubscription> subscriptionFuture = serverTransport.openSubscription("leader-management-request-handler", this, this); actor.runOnCompletion( subscriptionFuture, (subscription, err) -> { if (err != null) { throw new RuntimeException(err); } else { actor.consume( subscription, () -> { if (subscription.poll() == 0) { actor.yield(); } }); } }); }
@Override protected void onActorStarting() { final ActorFuture<ServerInputSubscription> openSubscriptionFuture = serverTransport.openSubscription("gossip", null, requestHandler);
@Override protected void onActorStarting() { final ActorFuture<ServerInputSubscription> openSubscriptionFuture = serverTransport.openSubscription("gossip", null, requestHandler);