Package org.apache.mina.common

Examples of org.apache.mina.common.SimpleByteBufferAllocator$SimpleByteBuffer


        org.apache.mina.common.ByteBuffer.setUseDirectBuffers(Boolean.getBoolean("amqj.enableDirectBuffers"));
        // the MINA default is currently to use the pooled allocator although this may change in future
        // once more testing of the performance of the simple allocator has been done
        if (!Boolean.getBoolean("amqj.enablePooledAllocator"))
        {
            org.apache.mina.common.ByteBuffer.setAllocator(new SimpleByteBufferAllocator());
        }

        SocketConnectorConfig cfg = (SocketConnectorConfig) _socketConnector.getDefaultConfig();
       
        SocketSessionConfig scfg = (SocketSessionConfig) cfg.getSessionConfig();
View Full Code Here


        // the MINA default is currently to use the pooled allocator although this may change in future
        // once more testing of the performance of the simple allocator has been done
        if (!Boolean.getBoolean("amqj.enablePooledAllocator"))
        {
            _logger.info("Using SimpleByteBufferAllocator");
            ByteBuffer.setAllocator(new SimpleByteBufferAllocator());
        }

        final IoConnector ioConnector = _socketConnectorFactory.newSocketConnector();
        final InetSocketAddress address;
View Full Code Here

        org.apache.mina.common.ByteBuffer.setUseDirectBuffers(Boolean.getBoolean("amqj.enableDirectBuffers"));
        // the MINA default is currently to use the pooled allocator although this may change in future
        // once more testing of the performance of the simple allocator has been done
        if (!Boolean.getBoolean("amqj.enablePooledAllocator"))
        {
            org.apache.mina.common.ByteBuffer.setAllocator(new SimpleByteBufferAllocator());
        }

        SocketConnectorConfig cfg = (SocketConnectorConfig) _socketConnector.getDefaultConfig();
        String s = "";
                    StackTraceElement[] trace = Thread.currentThread().getStackTrace();
View Full Code Here

  public void start() throws Exception {
    initIOHandler();

    ByteBuffer.setUseDirectBuffers(!useHeapBuffers); // this is global, oh well.
    if (useHeapBuffers)
      ByteBuffer.setAllocator(new SimpleByteBufferAllocator()); // dont pool for heap buffers.

    log.info("MRTMP Mina Transport Settings");
    log.info("IO Threads: " + ioThreads);
    log.info("Event Threads:" + " core: " + eventThreadsCore + "+1"
        + " max: " + eventThreadsMax + "+1" + " queue: "
View Full Code Here

  public void start() throws Exception {
    initIOHandler();

    ByteBuffer.setUseDirectBuffers(!useHeapBuffers); // this is global, oh well.
    if (useHeapBuffers) {
      ByteBuffer.setAllocator(new SimpleByteBufferAllocator()); // dont pool for heap buffers.
        }
    log.info("RTMP Mina Transport Settings");
    log.info("IO Threads: {}", ioThreads);
    log.info("Event Threads - core: {}, max: {}, queue: {}, keepalive: {}", new Object[]{eventThreadsCore, eventThreadsMax, eventThreadsQueue, eventThreadsKeepalive});
View Full Code Here

  }
 
  public static void initNetPort() throws IOException
  {
        ByteBuffer.setUseDirectBuffers(false);
        ByteBuffer.setAllocator(new SimpleByteBufferAllocator());
       
        IoAcceptor acceptor = new SocketAcceptor();
        IoAcceptorConfig config = new SocketAcceptorConfig();
        acceptor.bind( new InetSocketAddress(PORT), new ProfilerServerHandler(), config);
        log.info("PBLabs Profiler server started on localhost:" + PORT);
View Full Code Here

  private void initService()
  {
    try
    {
      ByteBuffer.setUseDirectBuffers(false);
      ByteBuffer.setAllocator(new SimpleByteBufferAllocator());

      acceptor =
        new SocketAcceptor(Runtime.getRuntime().availableProcessors() + 1, Executors.newCachedThreadPool());

      // JMX instrumentation
View Full Code Here

TOP

Related Classes of org.apache.mina.common.SimpleByteBufferAllocator$SimpleByteBuffer

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.