diff options
author | Tony Garnock-Jones <tonygarnockjones@gmail.com> | 2010-06-06 12:34:12 +1200 |
---|---|---|
committer | Tony Garnock-Jones <tonygarnockjones@gmail.com> | 2010-06-06 12:34:12 +1200 |
commit | 2cb889e61dda04c6d4dd6bdd3622784021b61435 (patch) | |
tree | 2ac2b9e3c5b91378a5f024f91135fc43e0d89713 /tools | |
parent | e6332b1edbe37c38241882225005c2e2cb686445 (diff) | |
download | rabbitmq-c-2cb889e61dda04c6d4dd6bdd3622784021b61435.tar.gz |
Documentation for amqp-{declare,delete}-queue
Diffstat (limited to 'tools')
-rw-r--r-- | tools/Makefile.am | 12 | ||||
-rw-r--r-- | tools/doc/declare_queue.xml | 122 | ||||
-rw-r--r-- | tools/doc/delete_queue.xml | 94 |
3 files changed, 227 insertions, 1 deletions
diff --git a/tools/Makefile.am b/tools/Makefile.am index 04397b2..6a52777 100644 --- a/tools/Makefile.am +++ b/tools/Makefile.am @@ -14,7 +14,13 @@ amqp_declare_queue_SOURCES = declare_queue.c common.c amqp_delete_queue_SOURCES = delete_queue.c common.c if TOOLS_DOC -man_MANS = doc/amqp-publish.1 doc/amqp-consume.1 doc/amqp-get.1 doc/librabbitmq-tools.7 +man_MANS = \ + doc/amqp-publish.1 \ + doc/amqp-consume.1 \ + doc/amqp-get.1 \ + doc/amqp-declare-queue.1 \ + doc/amqp-delete-queue.1 \ + doc/librabbitmq-tools.7 MOSTLYCLEANFILES = doc/man-date.ent # automake complains about % pattern rules, and suffix rules don't @@ -25,6 +31,10 @@ doc/amqp-consume.1: doc/consume.xml doc/man-date.ent $(XMLTO) man -o doc $< doc/amqp-get.1: doc/get.xml doc/man-date.ent $(XMLTO) man -o doc $< +doc/amqp-declare-queue.1: doc/declare_queue.xml doc/man-date.ent + $(XMLTO) man -o doc $< +doc/amqp-delete-queue.1: doc/delete_queue.xml doc/man-date.ent + $(XMLTO) man -o doc $< doc/librabbitmq-tools.7: doc/librabbitmq-tools.xml doc/man-date.ent $(XMLTO) man -o doc $< diff --git a/tools/doc/declare_queue.xml b/tools/doc/declare_queue.xml new file mode 100644 index 0000000..7e9da32 --- /dev/null +++ b/tools/doc/declare_queue.xml @@ -0,0 +1,122 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.docbook.org/xml/4.5/docbookx.dtd" +[ +<!ENTITY date SYSTEM "man-date.ent" > +] +> +<refentry lang="en"> + <refentryinfo> + <productname>RabbitMQ C Client</productname> + <authorgroup> + <corpauthor>The RabbitMQ Team <<ulink url="mailto:info@rabbitmq.com"><email>info@rabbitmq.com</email></ulink>></corpauthor> + </authorgroup> + <date>&date;</date> + </refentryinfo> + + <refmeta> + <refentrytitle>amqp-declare-queue</refentrytitle> + <manvolnum>1</manvolnum> + <refmiscinfo class="manual">RabbitMQ C Client</refmiscinfo> + </refmeta> + + <refnamediv> + <refname>amqp-declare-queue</refname> + <refpurpose>Declare (create or assert the existence of) a queue on an AMQP server</refpurpose> + </refnamediv> + + <refsynopsisdiv> + <cmdsynopsis> + <command>amqp-declare-queue</command> + <arg choice="opt" rep="repeat"> + <replaceable>OPTION</replaceable> + </arg> + <arg choice="opt">-d</arg> + <arg choice="req">-q <replaceable>queue name</replaceable></arg> + </cmdsynopsis> + </refsynopsisdiv> + + <refsect1> + <title>Description</title> + <para> + <command>amqp-declare-queue</command> attempts to create a + queue on an AMQP server, and exits. If the empty-string is + supplied as the queue name, a fresh queue name is + generated by the server and returned. In all cases, if a + queue was successfully declared, the (raw binary) name of + the queue is printed to standard output, followed by a + newline. + </para> + </refsect1> + + <refsect1> + <title>Options</title> + <variablelist> + <varlistentry> + <term><option>-q</option></term> + <term><option>--queue</option>=<replaceable class="parameter">queue name</replaceable></term> + <listitem> + <para> + The name of the queue to declare. If the + empty string is supplied, a fresh queue name + is generated by the server. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><option>-d</option></term> + <term><option>--durable</option></term> + <listitem> + <para> + Causes the queue to be declared with the + "durable" flag set. Durable queues survive + server restarts. By default, queues are declared + in "transient" mode. + </para> + </listitem> + </varlistentry> + </variablelist> + </refsect1> + + <refsect1> + <title>Exit Status</title> + <para> + If the queue was successfully declared, the exit status is + 0. If an error occurs, the exit status is 1. + </para> + </refsect1> + + <refsect1> + <title>Examples</title> + <variablelist> + <varlistentry> + <term>Declare the durable queue <quote><systemitem + class="resource">myqueue</systemitem></quote>, and + display the name of the queue on standard output:</term> + <listitem> + <screen><prompt>$ </prompt><userinput>amqp-declare-queue -d -q myqueue</userinput> +myqueue</screen> + </listitem> + </varlistentry> + <varlistentry> + <term>Declare a fresh, server-named transient queue, + and display the name of the queue on standard output + (use <citerefentry><refentrytitle>amqp-delete-queue</refentrytitle> + <manvolnum>1</manvolnum></citerefentry> to delete + it from the server once you're done):</term> + <listitem> + <screen><prompt>$ </prompt><userinput>amqp-declare-queue -q ""</userinput> +amq.gen-BW/wvociA8g6LFpb1PlqOA==</screen> + </listitem> + </varlistentry> + </variablelist> + </refsect1> + + <refsect1> + <title>See also</title> + <para> + <citerefentry><refentrytitle>librabbitmq-tools</refentrytitle><manvolnum>7</manvolnum></citerefentry> + describes connection-related options common to all the + RabbitMQ C Client tools. + </para> + </refsect1> +</refentry> diff --git a/tools/doc/delete_queue.xml b/tools/doc/delete_queue.xml new file mode 100644 index 0000000..69d03d8 --- /dev/null +++ b/tools/doc/delete_queue.xml @@ -0,0 +1,94 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.docbook.org/xml/4.5/docbookx.dtd" +[ +<!ENTITY date SYSTEM "man-date.ent" > +] +> +<refentry lang="en"> + <refentryinfo> + <productname>RabbitMQ C Client</productname> + <authorgroup> + <corpauthor>The RabbitMQ Team <<ulink url="mailto:info@rabbitmq.com"><email>info@rabbitmq.com</email></ulink>></corpauthor> + </authorgroup> + <date>&date;</date> + </refentryinfo> + + <refmeta> + <refentrytitle>amqp-delete-queue</refentrytitle> + <manvolnum>1</manvolnum> + <refmiscinfo class="manual">RabbitMQ C Client</refmiscinfo> + </refmeta> + + <refnamediv> + <refname>amqp-delete-queue</refname> + <refpurpose>Delete a queue from an AMQP server</refpurpose> + </refnamediv> + + <refsynopsisdiv> + <cmdsynopsis> + <command>amqp-delete-queue</command> + <arg choice="opt" rep="repeat"> + <replaceable>OPTION</replaceable> + </arg> + <arg choice="req">-q <replaceable>queue name</replaceable></arg> + </cmdsynopsis> + </refsynopsisdiv> + + <refsect1> + <title>Description</title> + <para> + <command>amqp-delete-queue</command> deletes a queue from + an AMQP server, and exits after printing to standard + output the number of messages that were in the queue at + the time of its deletion. + </para> + </refsect1> + + <refsect1> + <title>Options</title> + <variablelist> + <varlistentry> + <term><option>-q</option></term> + <term><option>--queue</option>=<replaceable class="parameter">queue name</replaceable></term> + <listitem> + <para> + The name of the queue to delete. + </para> + </listitem> + </varlistentry> + </variablelist> + </refsect1> + + <refsect1> + <title>Exit Status</title> + <para> + If the queue was successfully deleted, the exit status is + 0. If an error occurs, the exit status is 1. + </para> + </refsect1> + + <refsect1> + <title>Examples</title> + <variablelist> + <varlistentry> + <term>Delete the + queue <quote><systemitem class="resource">myqueue</systemitem></quote> + at a moment when it has 123 messages waiting on + it:</term> + <listitem> + <screen><prompt>$ </prompt><userinput>amqp-delete-queue -q myqueue</userinput> +123</screen> + </listitem> + </varlistentry> + </variablelist> + </refsect1> + + <refsect1> + <title>See also</title> + <para> + <citerefentry><refentrytitle>librabbitmq-tools</refentrytitle><manvolnum>7</manvolnum></citerefentry> + describes connection-related options common to all the + RabbitMQ C Client tools. + </para> + </refsect1> +</refentry> |