Package org.jboss.netty.channel

Examples of org.jboss.netty.channel.ChannelFactory


     *         if the factory is not set for this bootstrap yet.
     *         The factory can be set in the constructor or
     *         {@link #setFactory(ChannelFactory)}.
     */
    public ChannelFactory getFactory() {
        ChannelFactory factory = this.factory;
        if (factory == null) {
            throw new IllegalStateException(
                    "factory is not set yet.");
        }
        return factory;
View Full Code Here


    /**
     * This method simply delegates the call to
     * {@link ChannelFactory#releaseExternalResources()}.
     */
    public void releaseExternalResources() {
        ChannelFactory factory = this.factory;
        if (factory != null) {
            factory.releaseExternalResources();
        }
    }
View Full Code Here

    /**
     * This method simply delegates the call to
     * {@link ChannelFactory#shutdown()}.
     */
    public void shutdown() {
        ChannelFactory factory = this.factory;
        if (factory != null) {
            factory.shutdown();
        }
    }
View Full Code Here

        String namePrefix = "http-client-" + name;

        // shared timer for channel factory and read timeout channel handler
        this.timer = new HashedWheelTimer(daemonThreadsNamed(namePrefix + "-timer-%s"));

        ChannelFactory channelFactory = new NioClientSocketChannelFactory(ioPool.getBossPool(), ioPool.getWorkerPool());

        ThreadFactory workerThreadFactory = daemonThreadsNamed(namePrefix + "-worker-%s");
        this.executor = new OrderedMemoryAwareThreadPoolExecutor(asyncConfig.getWorkerThreads(), 0, 0, 30, TimeUnit.SECONDS, workerThreadFactory);
        this.executorMBean = new ThreadPoolExecutorMBean(executor);
View Full Code Here

    this.socketAddress = socketAddress;
    this.filterBySub = filterBySub;
    runner = executor;

    final ChannelFactory channelFactory =
        new NioServerSocketChannelFactory(executor, executor);

    boot = new ServerBootstrap(channelFactory);

    final ChannelPipelineFactory pipelineFactory = new PipelineFactoryDDF(this);
View Full Code Here

     *         if the factory is not set for this bootstrap yet.
     *         The factory can be set in the constructor or
     *         {@link #setFactory(ChannelFactory)}.
     */
    public ChannelFactory getFactory() {
        ChannelFactory factory = this.factory;
        if (factory == null) {
            throw new IllegalStateException(
                    "factory is not set yet.");
        }
        return factory;
View Full Code Here

     *         if the factory is not set for this bootstrap yet.
     *         The factory can be set in the constructor or
     *         {@link #setFactory(ChannelFactory)}.
     */
    public ChannelFactory getFactory() {
        ChannelFactory factory = this.factory;
        if (factory == null) {
            throw new IllegalStateException(
                    "factory is not set yet.");
        }
        return factory;
View Full Code Here

    return db.getCollection(collectionName);
  }

  public void start() {
    data = new ConcurrentHashMap<String, MockDB>();
    final ChannelFactory factory = new NioServerSocketChannelFactory(
        Executors.newCachedThreadPool(), Executors
            .newCachedThreadPool());

    channels = new DefaultChannelGroup("jmockmongo");
    bootstrap = new ServerBootstrap(factory);
View Full Code Here

     *         if the factory is not set for this bootstrap yet.
     *         The factory can be set in the constructor or
     *         {@link #setFactory(ChannelFactory)}.
     */
    public ChannelFactory getFactory() {
        ChannelFactory factory = this.factory;
        if (factory == null) {
            throw new IllegalStateException(
                    "factory is not set yet.");
        }
        return factory;
View Full Code Here

    /**
     * {@inheritDoc}  This method simply delegates the call to
     * {@link ChannelFactory#releaseExternalResources()}.
     */
    public void releaseExternalResources() {
        ChannelFactory factory = this.factory;
        if (factory != null) {
            factory.releaseExternalResources();
        }
    }
View Full Code Here

TOP

Related Classes of org.jboss.netty.channel.ChannelFactory

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.