private void addWorker ( ) { Throwable ex = null ; ForkJoinWorkerThread wt = null ; try { if ( ( wt = factory . newThread ( this ) ) != null ) { wt . start ( ) ; return ; } } catch ( Throwable e ) { ex = e ; } deregisterWorker ( wt , ex ) ; // adjust counts etc on failure }
Tries to create and start a worker