refactor to use LinkedBlockingQueue