blob: 7b1a36707df0e9321fcf3b382fbf7df4871ef8f0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
|
<?xml version="1.0" encoding="utf-8"?>
<chapter xmlns:html="http://www.w3.org/1999/xhtml"><title>
Apache Qpid : BindingURLFormat
</title>
<programlisting>
<Exchange Class>://<Exchange Name>/[<Destination>]/[<Queue>][?<option>='<value>'[&<option>='<value>']]
</programlisting>
<para>
This URL format is used for two purposes in the code base. The
broker uses this in the XML configuration file to create and bind
queues at broker startup. It is also used by the client as a
destination.
</para><para>
This format was used because it allows an explicit description of
exchange and queue relationship.
</para><para>
The Exchange Class is not normally required for client connection
as clients only publish to a named exchange however if exchanges
are being dynamically instantiated it will be required. The class
is required for the server to instantiate an exchange.
</para><para>
There are a number of options that are currently defined:
</para><table><title/><tgroup cols="3">
<tbody>
<row>
<entry>
Option
</entry>
<entry>
type
</entry>
<entry>
Description
</entry>
</row>
<row>
<entry>
exclusive
</entry>
<entry>
boolean
</entry>
<entry>
Is this an exclusive connection
</entry>
</row>
<row>
<entry>
autodelete
</entry>
<entry>
boolean
</entry>
<entry>
Should this queue be deleted on client disconnection
</entry>
</row>
<row>
<entry>
durable
</entry>
<entry>
boolean
</entry>
<entry>
Create a durable queue
</entry>
</row>
<row>
<entry>
clientid
</entry>
<entry>
string
</entry>
<entry>
Use the following client id
</entry>
</row>
<row>
<entry>
subscription
</entry>
<entry>
boolean
</entry>
<entry>
Create a subscription to this destination
</entry>
</row>
<row>
<entry>
routingkey
</entry>
<entry>
string
</entry>
<entry>
Use this value as the routing key
</entry>
</row>
</tbody>
</tgroup></table><para>
Using these options in conjunction with the Binding URL format
should allow future expansion as new and custom exchange types
are created.
</para><para>
The URL format requires <emphasis>that at least one</emphasis> Queue or
routingkey option be present on the URL.
</para><para>
The routingkey would be used to encode a topic as shown in the
examples section below.
</para>
<section role="h4" id="BindingURLFormat-Examples">
<title>
Examples
</title>
<example>
<title> Queues</title>
<para>
A queue can be created in QPID using the following URL format.
</para><para>
direct://amq.direct//<Queue Name>
</para><para>
For example: direct://amq.direct//simpleQueue
</para><para>
Queue names may consist of any mixture of digits, letters, and
underscores.
</para>
</example>
<example>
<title>Topics</title>
<para>
A topic can be created in QPID using the following URL format.
</para><para>
topic://amq.topic/<Topic Subscription>/
</para><para>
The topic subscription may only contain the letters A-Z and a-z
and digits 0-9.
</para>
<programlisting>
direct://amq.direct/SimpleQueue
direct://amq.direct/UnusuallyBoundQueue?routingkey='/queue'
topic://amq.topic?routingkey='stocks.#'
topic://amq.topic?routingkey='stocks.nyse.ibm'
</programlisting>
</example>
<!--h4--></section>
</chapter>
|