If processing failed because the database is down, retrying at once is pointless: the database needs time to come back. So the queue work sends a rejected message to the retry queue work.retry, which has a TTL set, and when the TTL runs out, the message reaches work again. How many rounds of this loop the message has already made is recorded in its header x-death.