int getNumBarriers() {
        return queue.size();
    }
Obtain the current number of pending barriers. This method is
intended for testing and debugging.

@return Number of pending barriers.
vespajlib/src/main/java/com/yahoo/concurrent/EventBarrier.java