Show Table of Contents
8.5.3. Create a durable queue in an application
The following example code creates a durable queue called "important-messages":
- C++
Sender sender = session.createSender("important-messages; {create:always, node:{durable: True}")- Python
newqueue = session.sender("important-messages; {create:always, node:{durable: True}")
Note that if a queue is declared
durable and auto-delete, it is only durable until it gets auto-deleted! Carefully consider if this is the behavior that you want.

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.