Cleaner exit of the work goroutines. Better queue locking semantics.
Re-add failed tasks to the queue using other function that doesn't panic once started.