Mercurial > hg > Database > Christie
diff src/main/java/christie/codegear/StartCodeGear.java @ 208:ef5aad739292
update priority
author | akahori |
---|---|
date | Sun, 10 Mar 2019 16:25:52 +0900 |
parents | ad49723367c2 |
children |
line wrap: on
line diff
--- a/src/main/java/christie/codegear/StartCodeGear.java Sat Mar 09 21:53:37 2019 +0900 +++ b/src/main/java/christie/codegear/StartCodeGear.java Sun Mar 10 16:25:52 2019 +0900 @@ -7,17 +7,19 @@ public abstract class StartCodeGear extends CodeGear{ static ConcurrentHashMap<Integer, CodeGearManager> cgmList = new ConcurrentHashMap<>(); - //static LinkedBlockingQueue<Runnable> taskQueue = new LinkedBlockingQueue<Runnable>(); - /*static ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(Runtime.getRuntime().availableProcessors(), // initial number of threads + /*static LinkedBlockingQueue<Runnable> taskQueue = new LinkedBlockingQueue<Runnable>(); + static ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(Runtime.getRuntime().availableProcessors(), // initial number of threads Runtime.getRuntime().availableProcessors(), Integer.MAX_VALUE, // keepAliveTime TimeUnit.SECONDS, taskQueue);*/ - static ThreadPoolExecutor threadPoolExecutor = PriorityThreadPoolExecutors.createThreadPool(Runtime.getRuntime().availableProcessors(), Integer.MAX_VALUE); + static ThreadPoolExecutor threadPoolExecutor = PriorityThreadPoolExecutors.createThreadPool(Runtime.getRuntime().availableProcessors(), + Integer.MAX_VALUE); static int cgmCount = 1; public StartCodeGear(CodeGearManager cgm){ cgm.setup(this); + } public static CodeGearManager createCGM(int localPort){ @@ -33,5 +35,4 @@ @Override protected void run(CodeGearManager cgm) {} - }