public SmppSimulatorServer(ExecutorService executors) { // used for tracking any child channels (sessions) this.sessionChannels = new DefaultChannelGroup(); // we'll put the "boss" worker for a server in its own pool this.bossThreadPool = Executors.newCachedThreadPool(); // a factory for creating channels (connections) this.channelFactory = new NioServerSocketChannelFactory(this.bossThreadPool, executors); // tie the server bootstrap to this server socket channel factory this.serverBootstrap = new ServerBootstrap(this.channelFactory); // the handler to use when new child connections are accepted this.serverHandler = new SmppSimulatorServerHandler(this.sessionChannels); // set up the event pipeline factory for new connections this.serverBootstrap.setParentHandler(serverHandler); }
public SmppSimulatorServer(ExecutorService executors) { // used for tracking any child channels (sessions) this.sessionChannels = new DefaultChannelGroup(); // we'll put the "boss" worker for a server in its own pool this.bossThreadPool = Executors.newCachedThreadPool(); // a factory for creating channels (connections) this.channelFactory = new NioServerSocketChannelFactory(this.bossThreadPool, executors); // tie the server bootstrap to this server socket channel factory this.serverBootstrap = new ServerBootstrap(this.channelFactory); // the handler to use when new child connections are accepted this.serverHandler = new SmppSimulatorServerHandler(this.sessionChannels); // set up the event pipeline factory for new connections this.serverBootstrap.setParentHandler(serverHandler); }
public SmppSimulatorServer(ExecutorService executors) { // used for tracking any child channels (sessions) this.sessionChannels = new DefaultChannelGroup(); // we'll put the "boss" worker for a server in its own pool this.bossThreadPool = Executors.newCachedThreadPool(); // a factory for creating channels (connections) this.channelFactory = new NioServerSocketChannelFactory(this.bossThreadPool, executors); // tie the server bootstrap to this server socket channel factory this.serverBootstrap = new ServerBootstrap(this.channelFactory); // the handler to use when new child connections are accepted this.serverHandler = new SmppSimulatorServerHandler(this.sessionChannels); // set up the event pipeline factory for new connections this.serverBootstrap.setParentHandler(serverHandler); }
public SmppSimulatorServer(ExecutorService executors) { // used for tracking any child channels (sessions) this.sessionChannels = new DefaultChannelGroup(); // we'll put the "boss" worker for a server in its own pool this.bossThreadPool = Executors.newCachedThreadPool(); // a factory for creating channels (connections) this.channelFactory = new NioServerSocketChannelFactory(this.bossThreadPool, executors); // tie the server bootstrap to this server socket channel factory this.serverBootstrap = new ServerBootstrap(this.channelFactory); // the handler to use when new child connections are accepted this.serverHandler = new SmppSimulatorServerHandler(this.sessionChannels); // set up the event pipeline factory for new connections this.serverBootstrap.setParentHandler(serverHandler); }