You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by Alan Conway <ac...@redhat.com> on 2007/01/08 16:09:40 UTC
Re: [CONF] Apache Qpid: BindingURLFormat (page edited)
On Mon, 2007-01-08 at 06:33 -0800, confluence@apache.org wrote:
> Page Edited : qpid : BindingURLFormat BindingURLFormat has been edited
> by Martin Ritchie (Jan 08, 2007).
>
> (View changes)
>
> Content:
> <Exchange Class>://<Exchange Name>/[<Queue>][?<option>='<value>'[&<option>='<value>']]
>
snip
> Examples
> direct://amq.direct/SimpleQueue
> direct://amq.direct/UnusuallyBoundQueue?routingkey='queue'
> topic://amq.topic?routingkey='stocks.#'
> topic://amq.topic?routingkey='stocks.nyse.ibm'
Using exchange types as the protocol prefix of a URL is a bad idea, you
would never be able to standardize it with IANA or whoever monitors
these things. The set of exchange types is open to change in the future
but URL protocol prefixes must be unique forever.
Also this format abuses the prefix://host/path convention for internet
protocols.
I'd suggest something like:
qpid://<host>[:<port>]/<exch class>:<exch name>/[etc. as above]
Long term we'll want vendor neutral standard AMQP URLs like:
amqp:...
But it would be a mistake to try to grab the amqp: prefix right away.
That would make transition to standard AMQP URL's *more* difficult in
the future because we'd have no easy way to distinguish between an AMQP
standard URL and an old qpid-proprietary URL for backwards
compatibility.
Cheers,
Alan.
RE: [CONF] Apache Qpid: BindingURLFormat (page edited)
Posted by Tomas Restrepo <to...@devdeo.com>.
> In that case it might be better to refer to it as a "binding identifier"
> or "binding name". It's not a URL at all, since it doesn't provide
> information how to locate a binding on the network. Its not a URI either
> since it can only be interpreted in the context of a broker, so it's not
> a universal identifier.
+1. I agree it's not really an URL, so calling that is misleading. That
said, I have to wonder about the format. Why does it have a prefix at all?
After all, it appears to me the prefix is carrying redundant information:
topic://amq.topic?routingkey='stocks.#'
direct://amq.direct/SimpleQueue
Notice that the prefix and the "host" part say the same anyway.
On the other hand, I might just be showing off my ignorance here :)
Tomas Restrepo
tomas.restrepo@devdeo.com
http://www.winterdom.com/weblog/
Re: [CONF] Apache Qpid: BindingURLFormat (page edited)
Posted by Martin Ritchie <ri...@apache.org>.
Agreed it is not really an URL as it is not universal. AMQ-RL seemed a
bit of a mouth full so perhaps identifier is better. The prefix isn't
redundant it just appears so in the provided examples. The
prefix://host format is:
<class>://<name>
The class is currently direct, topic or headers the name can be any
value. The AMQP spec requires that the broker declares corresponding
default exchanges: amq.direct, amq.topic, amq.headers; but any name is
valid hence the prefix is used to identify the class of exchange.
On 09/01/07, Tomas Restrepo <to...@devdeo.com> wrote:
>
> > In that case it might be better to refer to it as a "binding identifier"
> > or "binding name". It's not a URL at all, since it doesn't provide
> > information how to locate a binding on the network. Its not a URI either
> > since it can only be interpreted in the context of a broker, so it's not
> > a universal identifier.
>
> +1. I agree it's not really an URL, so calling that is misleading. That
> said, I have to wonder about the format. Why does it have a prefix at all?
> After all, it appears to me the prefix is carrying redundant information:
>
> topic://amq.topic?routingkey='stocks.#'
> direct://amq.direct/SimpleQueue
>
> Notice that the prefix and the "host" part say the same anyway.
> On the other hand, I might just be showing off my ignorance here :)
>
>
> Tomas Restrepo
> tomas.restrepo@devdeo.com
> http://www.winterdom.com/weblog/
>
>
>
>
>
--
Martin Ritchie
Re: [CONF] Apache Qpid: BindingURLFormat (page edited)
Posted by Alan Conway <ac...@redhat.com>.
On Mon, 2007-01-08 at 15:37 +0000, Martin Ritchie wrote:
[snip]
> > > Examples
> > > direct://amq.direct/SimpleQueue
> > > direct://amq.direct/UnusuallyBoundQueue?routingkey='queue'
> > > topic://amq.topic?routingkey='stocks.#'
> > > topic://amq.topic?routingkey='stocks.nyse.ibm'
> >
> > Using exchange types as the protocol prefix of a URL is a bad idea, you
> > would never be able to standardize it with IANA or whoever monitors
> > these things. The set of exchange types is open to change in the future
> > but URL protocol prefixes must be unique forever.
> >
> > Also this format abuses the prefix://host/path convention for internet
> > protocols.
>
> This isn't an Internet protocol URL it just looks like one. This is a
> BindingURL for binding a Destination(Queue/Topic/Header) to a routing
> key. IANA should have nothing to say about it. The AMQP WG do need to
> define this for interop.
In that case it might be better to refer to it as a "binding identifier"
or "binding name". It's not a URL at all, since it doesn't provide
information how to locate a binding on the network. Its not a URI either
since it can only be interpreted in the context of a broker, so it's not
a universal identifier.
Cheers,
Alan.
Re: [CONF] Apache Qpid: BindingURLFormat (page edited)
Posted by Martin Ritchie <ri...@apache.org>.
On 08/01/07, Alan Conway <ac...@redhat.com> wrote:
> On Mon, 2007-01-08 at 06:33 -0800, confluence@apache.org wrote:
> > Page Edited : qpid : BindingURLFormat BindingURLFormat has been edited
> > by Martin Ritchie (Jan 08, 2007).
> >
> > (View changes)
> >
> > Content:
> > <Exchange Class>://<Exchange Name>/[<Queue>][?<option>='<value>'[&<option>='<value>']]
> >
> snip
>
> > Examples
> > direct://amq.direct/SimpleQueue
> > direct://amq.direct/UnusuallyBoundQueue?routingkey='queue'
> > topic://amq.topic?routingkey='stocks.#'
> > topic://amq.topic?routingkey='stocks.nyse.ibm'
>
> Using exchange types as the protocol prefix of a URL is a bad idea, you
> would never be able to standardize it with IANA or whoever monitors
> these things. The set of exchange types is open to change in the future
> but URL protocol prefixes must be unique forever.
>
> Also this format abuses the prefix://host/path convention for internet
> protocols.
This isn't an Internet protocol URL it just looks like one. This is a
BindingURL for binding a Destination(Queue/Topic/Header) to a routing
key. IANA should have nothing to say about it. The AMQP WG do need to
define this for interop.
IANA would need to agree the ConnectionURL as described on this page
(http://cwiki.apache.org/confluence/display/qpid/ConnectionURLFormat)
which does start amqp:// and is used for performing connections as an
Internet protocol. Although it too does abuse to format of
prefix://host/path as AMQP connections are not constrained to a single
host.
amqp://[<user>:<pass>@][<clientid>]<virtualhost>[?<option>='<value>'[&<option>='<value>']]
As you can see the 'host' value is the client_id.
Other suggestions are welcome. We have these two url formats in
production use where we need to specify multiple hosts for failover.
One approach would be to put the 'first' broker as the host:port and
the rest as parameters but this just seems wrong as you are some how
saying one broker is more important than the others.
> I'd suggest something like:
> qpid://<host>[:<port>]/<exch class>:<exch name>/[etc. as above]
>
>
> Long term we'll want vendor neutral standard AMQP URLs like:
> amqp:...
> But it would be a mistake to try to grab the amqp: prefix right away.
> That would make transition to standard AMQP URL's *more* difficult in
> the future because we'd have no easy way to distinguish between an AMQP
> standard URL and an old qpid-proprietary URL for backwards
> compatibility.
>
> Cheers,
> Alan.
>
>
--
Martin Ritchie