public boolean openQueueTracer ( ) { final int TRIALS = 5 ; int tracerCounter = 0 , trialCounter = 0 ; boolean success = false ; do { this . queueWriteLock . lock ( ) ; try { if ( this . queueConfig . enabled ) { for ( QueueTracer < ? > queueTracer : this . queueConfig . blockingTracerDeque ) { if ( ! queueTracer . isOpened ( ) ) { queueTracer . open ( ) ; tracerCounter ++ ; if ( tracerCounter == this . queueConfig . size ) success = true ; } } } } finally { this . queueWriteLock . unlock ( ) ; } trialCounter ++ ; } while ( tracerCounter < this . queueConfig . size && trialCounter < TRIALS ) ; return success ; }
Tries to open all enqueued QueueTracer .