Intelligently assign queues to workers