channel.queue_declare(queue='hello', durable=True)
channel.queue_bind(exchange='amq.direct', queue='hello')
delay_channel = connection.channel()
delay_channel.confirm_delivery()
delay_channel.queue_declare(queue='hello_delay', durable=True, arguments={
    'x-message-ttl': 5000, 'x-dead-letter-exchange': 'amq.direct',
    'x-dead-letter-routing-key': 'hello'})
delay_channel.basic_publish(exchange='', routing_key='hello_delay', body=
    'test', properties=pika.BasicProperties(delivery_mode=2))
print(' [x] Sent')
Как создать отложенную очередь в RabbitMQ?