private Networking createNetworking(Node node, NodeIOService ioService) { ChannelInitializer initializer = node.getNodeExtension().createChannelInitializer(ioService); LoggingServiceImpl loggingService = node.loggingService; ChannelErrorHandler errorHandler = new TcpIpConnectionChannelErrorHandler(loggingService.getLogger(TcpIpConnectionChannelErrorHandler.class)); HazelcastProperties props = node.getProperties(); return new NioNetworking( new NioNetworking.Context() .loggingService(loggingService) .metricsRegistry(node.nodeEngine.getMetricsRegistry()) .threadNamePrefix(node.hazelcastInstance.getName()) .errorHandler(errorHandler) .inputThreadCount(props.getInteger(IO_INPUT_THREAD_COUNT)) .outputThreadCount(props.getInteger(IO_OUTPUT_THREAD_COUNT)) .balancerIntervalSeconds(props.getInteger(IO_BALANCER_INTERVAL_SECONDS)) .channelInitializer(initializer)); } }
private Networking createNetworking(Node node, NodeIOService ioService) { ChannelInitializer initializer = node.getNodeExtension().createChannelInitializer(ioService); LoggingServiceImpl loggingService = node.loggingService; ChannelErrorHandler errorHandler = new TcpIpConnectionChannelErrorHandler(loggingService.getLogger(TcpIpConnectionChannelErrorHandler.class)); HazelcastProperties props = node.getProperties(); return new NioNetworking( new NioNetworking.Context() .loggingService(loggingService) .metricsRegistry(node.nodeEngine.getMetricsRegistry()) .threadNamePrefix(node.hazelcastInstance.getName()) .errorHandler(errorHandler) .inputThreadCount(props.getInteger(IO_INPUT_THREAD_COUNT)) .outputThreadCount(props.getInteger(IO_OUTPUT_THREAD_COUNT)) .balancerIntervalSeconds(props.getInteger(IO_BALANCER_INTERVAL_SECONDS)) .channelInitializer(initializer)); } }