Add template for blocking non-blocking queues