Java源码示例:org.apache.flink.runtime.concurrent.akka.ActorSystemScheduledExecutorAdapter

示例1
public AkkaRpcService(final ActorSystem actorSystem, final AkkaRpcServiceConfiguration configuration) {
	this.actorSystem = checkNotNull(actorSystem, "actor system");
	this.configuration = checkNotNull(configuration, "akka rpc service configuration");

	Address actorSystemAddress = AkkaUtils.getAddress(actorSystem);

	if (actorSystemAddress.host().isDefined()) {
		address = actorSystemAddress.host().get();
	} else {
		address = "";
	}

	if (actorSystemAddress.port().isDefined()) {
		port = (Integer) actorSystemAddress.port().get();
	} else {
		port = -1;
	}

	internalScheduledExecutor = new ActorSystemScheduledExecutorAdapter(actorSystem);

	terminationFuture = new CompletableFuture<>();

	stopped = false;
}
 
示例2
public AkkaRpcService(final ActorSystem actorSystem, final AkkaRpcServiceConfiguration configuration) {
	this.actorSystem = checkNotNull(actorSystem, "actor system");
	this.configuration = checkNotNull(configuration, "akka rpc service configuration");

	Address actorSystemAddress = AkkaUtils.getAddress(actorSystem);

	if (actorSystemAddress.host().isDefined()) {
		address = actorSystemAddress.host().get();
	} else {
		address = "";
	}

	if (actorSystemAddress.port().isDefined()) {
		port = (Integer) actorSystemAddress.port().get();
	} else {
		port = -1;
	}

	internalScheduledExecutor = new ActorSystemScheduledExecutorAdapter(actorSystem);

	terminationFuture = new CompletableFuture<>();

	stopped = false;
}
 
示例3
@VisibleForTesting
public AkkaRpcService(final ActorSystem actorSystem, final AkkaRpcServiceConfiguration configuration) {
	this.actorSystem = checkNotNull(actorSystem, "actor system");
	this.configuration = checkNotNull(configuration, "akka rpc service configuration");

	Address actorSystemAddress = AkkaUtils.getAddress(actorSystem);

	if (actorSystemAddress.host().isDefined()) {
		address = actorSystemAddress.host().get();
	} else {
		address = "";
	}

	if (actorSystemAddress.port().isDefined()) {
		port = (Integer) actorSystemAddress.port().get();
	} else {
		port = -1;
	}

	captureAskCallstacks = configuration.captureAskCallStack();

	internalScheduledExecutor = new ActorSystemScheduledExecutorAdapter(actorSystem);

	terminationFuture = new CompletableFuture<>();

	stopped = false;

	supervisor = startSupervisorActor();
}