Package org.glassfish.grizzly.memory

Examples of org.glassfish.grizzly.memory.ThreadLocalPoolProvider


       
        return new ThreadFactory() {
            @Override
            public Thread newThread(Runnable r) {
                final MemoryManager mm = config.getMemoryManager();
                final ThreadLocalPoolProvider threadLocalPoolProvider;
               
                if (mm instanceof ThreadLocalPoolProvider) {
                    threadLocalPoolProvider = (ThreadLocalPoolProvider) mm;
                } else {
                    threadLocalPoolProvider = null;
                }
               
                final DefaultWorkerThread thread =
                        new DefaultWorkerThread(Grizzly.DEFAULT_ATTRIBUTE_BUILDER,
                        config.getPoolName() + '(' + counter.incrementAndGet() + ')',
                                               ((threadLocalPoolProvider != null) ? threadLocalPoolProvider.createThreadLocalPool() : null),
                                               r);

                thread.setUncaughtExceptionHandler(AbstractThreadPool.this);
                thread.setPriority(config.getPriority());
                thread.setDaemon(config.isDaemon());
View Full Code Here

TOP

Related Classes of org.glassfish.grizzly.memory.ThreadLocalPoolProvider

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.