import java.util.List;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
+import java.util.concurrent.ThreadFactory;
import java.util.concurrent.TimeUnit;
import net.sf.openrocket.database.ThrustCurveMotorSet;
private BookKeeping() {
- writerThread = Executors.newSingleThreadExecutor();
-
- loaderPool = Executors.newFixedThreadPool(25);
+ writerThread = Executors.newSingleThreadExecutor( new ThreadFactory() {
+ @Override
+ public Thread newThread(Runnable r) {
+ Thread t = new Thread(r,"MotorWriterThread");
+ return t;
+ }
+ });
+
+ loaderPool = Executors.newFixedThreadPool(25, new ThreadFactory() {
+ int threadCount = 0;
+ @Override
+ public Thread newThread(Runnable r) {
+ Thread t = new Thread(r,"MotorLoaderPool-" + threadCount++);
+ return t;
+ }
+ });
workGenerator = new WorkGenerator();