Worker for a task queue