public PoolSchedulable getPool ( PoolInfo poolInfo ) { PoolSchedulable pool = nameToMap . get ( poolInfo ) ; if ( pool == null ) { pool = new PoolSchedulable ( poolInfo , getType ( ) , configManager ) ; PoolSchedulable prevPool = nameToMap . putIfAbsent ( poolInfo , pool ) ; if ( prevPool != null ) { pool = prevPool ; } } return pool ; }
Get a pool creating it if it does not exist . Note that these pools are never removed .