private static void initializeActorSystem(String hostname) throws UnknownHostException { synchronized (actorSystemLock) { if (actorSystem == null) { Configuration config = new Configuration(); Option<scala.Tuple2<String, Object>> remoting = new Some<>(new scala.Tuple2<String, Object>(hostname, 0)); Config akkaConfig = AkkaUtils.getAkkaConfig(config, remoting); LOG.info("Start actory system."); actorSystem = ActorSystem.create("queryableWindow", akkaConfig); actorSystemUsers = 1; } else { LOG.info("Actor system has already been started."); actorSystemUsers++; } } }
private static void initializeActorSystem(String hostname) throws UnknownHostException { synchronized (actorSystemLock) { if (actorSystem == null) { Configuration config = new Configuration(); Option<scala.Tuple2<String, Object>> remoting = new Some<>(new scala.Tuple2<String, Object>(hostname, 0)); Config akkaConfig = AkkaUtils.getAkkaConfig(config, remoting); LOG.info("Start actory system."); actorSystem = ActorSystem.create("queryableWindow", akkaConfig); actorSystemUsers = 1; } else { LOG.info("Actor system has already been started."); actorSystemUsers++; } } }
/** * Factory method to instantiate the RPC service. * * @param configuration * The configuration of the mini cluster * @param askTimeout * The default RPC timeout for asynchronous "ask" requests. * @param remoteEnabled * True, if the RPC service should be reachable from other (remote) RPC services. * @param bindAddress * The address to bind the RPC service to. Only relevant when "remoteEnabled" is true. * * @return The instantiated RPC service */ protected RpcService createRpcService( Configuration configuration, Time askTimeout, boolean remoteEnabled, String bindAddress) { final Config akkaConfig; if (remoteEnabled) { akkaConfig = AkkaUtils.getAkkaConfig(configuration, bindAddress, 0); } else { akkaConfig = AkkaUtils.getAkkaConfig(configuration); } final Config effectiveAkkaConfig = AkkaUtils.testDispatcherConfig().withFallback(akkaConfig); final ActorSystem actorSystem = AkkaUtils.createActorSystem(effectiveAkkaConfig); return new AkkaRpcService(actorSystem, askTimeout); }
/** * Factory method to instantiate the RPC service. * * @param configuration * The configuration of the mini cluster * @param askTimeout * The default RPC timeout for asynchronous "ask" requests. * @param remoteEnabled * True, if the RPC service should be reachable from other (remote) RPC services. * @param bindAddress * The address to bind the RPC service to. Only relevant when "remoteEnabled" is true. * * @return The instantiated RPC service */ protected RpcService createRpcService( Configuration configuration, Time askTimeout, boolean remoteEnabled, String bindAddress) { final Config akkaConfig; if (remoteEnabled) { akkaConfig = AkkaUtils.getAkkaConfig(configuration, bindAddress, 0); } else { akkaConfig = AkkaUtils.getAkkaConfig(configuration); } final Config effectiveAkkaConfig = AkkaUtils.testDispatcherConfig().withFallback(akkaConfig); final ActorSystem actorSystem = AkkaUtils.createActorSystem(effectiveAkkaConfig); return new AkkaRpcService(actorSystem, askTimeout); }
/** * Factory method to instantiate the RPC service. * * @param configuration * The configuration of the mini cluster * @param askTimeout * The default RPC timeout for asynchronous "ask" requests. * @param remoteEnabled * True, if the RPC service should be reachable from other (remote) RPC services. * @param bindAddress * The address to bind the RPC service to. Only relevant when "remoteEnabled" is true. * * @return The instantiated RPC service */ protected RpcService createRpcService( Configuration configuration, Time askTimeout, boolean remoteEnabled, String bindAddress) { final Config akkaConfig; if (remoteEnabled) { akkaConfig = AkkaUtils.getAkkaConfig(configuration, bindAddress, 0); } else { akkaConfig = AkkaUtils.getAkkaConfig(configuration); } final Config effectiveAkkaConfig = AkkaUtils.testDispatcherConfig().withFallback(akkaConfig); final ActorSystem actorSystem = AkkaUtils.createActorSystem(effectiveAkkaConfig); return new AkkaRpcService(actorSystem, askTimeout); }
Config akkaConfig = AkkaUtils.getAkkaConfig( configuration, new scala.Some<>(new scala.Tuple2<String, Object>(listeningAddress, listeningPort))
akkaConfig = AkkaUtils.getAkkaConfig(configuration, hostname, port); } else { akkaConfig = AkkaUtils.getAkkaConfig(configuration);
: AkkaUtils.getAkkaConfig(configuration, externalAddress);
Config akkaConfig = AkkaUtils.getAkkaConfig( configuration, new Some<>(new Tuple2<>(listeningAddress, listeningPort)),
Config akkaConfig = AkkaUtils.getAkkaConfig( configuration, new Some<>(new Tuple2<>(listeningAddress, listeningPort)),
akkaConfig = AkkaUtils.getAkkaConfig(configuration, hostname, port); } else { akkaConfig = AkkaUtils.getAkkaConfig(configuration);