Update polling of the queue. Other fixes.