Package org.glassfish.enterprise.concurrent

Examples of org.glassfish.enterprise.concurrent.ManagedThreadFactoryImpl


    }

    @Override
    void startValue(StartContext context) throws StartException {
        final String threadFactoryName = "EE-ManagedThreadFactory-"+name;
        managedThreadFactory = new ManagedThreadFactoryImpl(threadFactoryName, contextService.getOptionalValue(), priority);
    }
View Full Code Here


        this.rejectPolicy = rejectPolicy;
    }

    @Override
    void startValue(StartContext context) throws StartException {
        ManagedThreadFactoryImpl managedThreadFactory = managedThreadFactoryInjectedValue.getOptionalValue();
        if(managedThreadFactory == null) {
            // if not injected create one using normal thread priority
            final String threadFactoryName = "EE-ManagedExecutorService-"+name;
            managedThreadFactory = new ManagedThreadFactoryImpl(threadFactoryName, null, Thread.NORM_PRIORITY);
        }
        executorService = new ManagedExecutorServiceImpl(name, managedThreadFactory, hungTaskThreshold, longRunningTasks, corePoolSize, maxPoolSize, keepAliveTime, keepAliveTimeUnit, threadLifeTime, queueCapacity, contextService.getOptionalValue(), rejectPolicy);
    }
View Full Code Here

        this.rejectPolicy = rejectPolicy;
    }

    @Override
    void startValue(StartContext context) throws StartException {
        ManagedThreadFactoryImpl managedThreadFactory = managedThreadFactoryInjectedValue.getOptionalValue();
        if(managedThreadFactory == null) {
            // if not injected create one using normal thread priority
            final String threadFactoryName = "EE-ManagedScheduledExecutorService-"+name;
            managedThreadFactory = new ManagedThreadFactoryImpl(threadFactoryName, null, Thread.NORM_PRIORITY);
        }
        executorService = new ManagedScheduledExecutorServiceImpl(name, managedThreadFactory, hungTaskThreshold, longRunningTasks, corePoolSize, keepAliveTime, keepAliveTimeUnit, threadLifeTime, contextService.getOptionalValue(), rejectPolicy);
    }
View Full Code Here

TOP

Related Classes of org.glassfish.enterprise.concurrent.ManagedThreadFactoryImpl

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.