private HostAndPort startStatsService() { Iface rpcProxy = TraceWrap.service(this); final Processor<Iface> processor; if (context.getThriftServerType() == ThriftServerType.SASL) { Iface tcProxy = TCredentialsUpdatingWrapper.service(rpcProxy, getClass(), getConfiguration()); processor = new Processor<>(tcProxy); } else { processor = new Processor<>(rpcProxy); } int port[] = getConfiguration().getPort(Property.GC_PORT); HostAndPort[] addresses = TServerUtils.getHostAndPorts(this.opts.getAddress(), port); long maxMessageSize = getConfiguration().getAsBytes(Property.GENERAL_MAX_MESSAGE_SIZE); try { ServerAddress server = TServerUtils.startTServer(getConfiguration(), context.getThriftServerType(), processor, this.getClass().getSimpleName(), "GC Monitor Service", 2, getConfiguration().getCount(Property.GENERAL_SIMPLETIMER_THREADPOOL_SIZE), 1000, maxMessageSize, context.getServerSslParams(), context.getSaslParams(), 0, addresses); log.debug("Starting garbage collector listening on " + server.address); return server.address; } catch (Exception ex) { // ACCUMULO-3651 Level changed to error and FATAL added to message for slf4j compatibility log.error("FATAL:", ex); throw new RuntimeException(ex); } }
private HostAndPort startTabletClientService() throws UnknownHostException { // start listening for client connection last clientHandler = new ThriftClientHandler(); Iface rpcProxy = TraceWrap.service(clientHandler); final Processor<Iface> processor; if (context.getThriftServerType() == ThriftServerType.SASL) { Iface tcredProxy = TCredentialsUpdatingWrapper.service(rpcProxy, ThriftClientHandler.class, getConfiguration()); processor = new Processor<>(tcredProxy); } else { processor = new Processor<>(rpcProxy); } HostAndPort address = startServer(context.getServerConfFactory().getSystemConfiguration(), clientAddress.getHost(), Property.TSERV_CLIENTPORT, processor, "Thrift Client Server"); log.info("address = {}", address); return address; }
final ThriftServerType serverType = service.getThriftServerType();
Iface rpcProxy = TraceWrap.service(haProxy); final Processor<Iface> processor; if (context.getThriftServerType() == ThriftServerType.SASL) { Iface tcredsProxy = TCredentialsUpdatingWrapper.service(rpcProxy, clientHandler.getClass(), getConfiguration());