Debian Codegraph @

tools/doc/amqp-declare-queue.xml

raw symbols SCIP
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.docbook.org/xml/4.5/docbookx.dtd"
3 [
4 <!ENTITY date SYSTEM "man-date.ent" >
5 ]
6 >
7 <refentry lang="en">
8 <refentryinfo>
9 <productname>RabbitMQ C Client</productname>
10 <authorgroup>
11 <corpauthor>The RabbitMQ Team &lt;<ulink url="mailto:[email protected]"><email>[email protected]</email></ulink>&gt;</corpauthor>
12 </authorgroup>
13 <date>&date;</date>
14 </refentryinfo>
15
16 <refmeta>
17 <refentrytitle>amqp-declare-queue</refentrytitle>
18 <manvolnum>1</manvolnum>
19 <refmiscinfo class="manual">RabbitMQ C Client</refmiscinfo>
20 </refmeta>
21
22 <refnamediv>
23 <refname>amqp-declare-queue</refname>
24 <refpurpose>Declare (create or assert the existence of) a queue on an AMQP server</refpurpose>
25 </refnamediv>
26
27 <refsynopsisdiv>
28 <cmdsynopsis>
29 <command>amqp-declare-queue</command>
30 <arg choice="opt" rep="repeat">
31 <replaceable>OPTION</replaceable>
32 </arg>
33 <arg choice="opt">-d</arg>
34 <arg choice="req">-q <replaceable>queue name</replaceable></arg>
35 </cmdsynopsis>
36 </refsynopsisdiv>
37
38 <refsect1>
39 <title>Description</title>
40 <para>
41 <command>amqp-declare-queue</command> attempts to create a
42 queue on an AMQP server, and exits. If the empty-string is
43 supplied as the queue name, a fresh queue name is
44 generated by the server and returned. In all cases, if a
45 queue was successfully declared, the (raw binary) name of
46 the queue is printed to standard output, followed by a
47 newline.
48 </para>
49 </refsect1>
50
51 <refsect1>
52 <title>Options</title>
53 <variablelist>
54 <varlistentry>
55 <term><option>-q</option></term>
56 <term><option>--queue</option>=<replaceable class="parameter">queue name</replaceable></term>
57 <listitem>
58 <para>
59 The name of the queue to declare. If the
60 empty string is supplied, a fresh queue name
61 is generated by the server.
62 </para>
63 </listitem>
64 </varlistentry>
65 <varlistentry>
66 <term><option>-d</option></term>
67 <term><option>--durable</option></term>
68 <listitem>
69 <para>
70 Causes the queue to be declared with the
71 "durable" flag set. Durable queues survive
72 server restarts. By default, queues are declared
73 in "transient" mode.
74 </para>
75 </listitem>
76 </varlistentry>
77 </variablelist>
78 </refsect1>
79
80 <refsect1>
81 <title>Exit Status</title>
82 <para>
83 If the queue was successfully declared, the exit status is
84 0. If an error occurs, the exit status is 1.
85 </para>
86 </refsect1>
87
88 <refsect1>
89 <title>Examples</title>
90 <variablelist>
91 <varlistentry>
92 <term>Declare the durable queue <quote><systemitem
93 class="resource">myqueue</systemitem></quote>, and
94 display the name of the queue on standard output:</term>
95 <listitem>
96 <screen><prompt>$ </prompt><userinput>amqp-declare-queue -d -q myqueue</userinput>
97 myqueue</screen>
98 </listitem>
99 </varlistentry>
100 <varlistentry>
101 <term>Declare a fresh, server-named transient queue,
102 and display the name of the queue on standard output
103 (use <citerefentry><refentrytitle>amqp-delete-queue</refentrytitle>
104 <manvolnum>1</manvolnum></citerefentry> to delete
105 it from the server once you're done):</term>
106 <listitem>
107 <screen><prompt>$ </prompt><userinput>amqp-declare-queue -q ""</userinput>
108 amq.gen-BW/wvociA8g6LFpb1PlqOA==</screen>
109 </listitem>
110 </varlistentry>
111 </variablelist>
112 </refsect1>
113
114 <refsect1>
115 <title>See also</title>
116 <para>
117 <citerefentry><refentrytitle>librabbitmq-tools</refentrytitle><manvolnum>7</manvolnum></citerefentry>
118 describes connection-related options common to all the
119 RabbitMQ C Client tools.
120 </para>
121 </refsect1>
122 </refentry>