Cheers Gordon,
It does indeed look very similar to the preceeding " else if (type == TYPE_EXCHANGE || type == TYPE_TOPIC) " block so it's almost certainly just a bit of copy/paste.

Incidentally I noticed in the preceeding block the following:

"
        try {
            std::pair<boost::shared_ptr<Exchange>, bool> result =
createExchange(name, exchangeType, durable, alternateExchange, arguments, userId, connectionId);
            if (!result.second) {
                throw ObjectAlreadyExists(name);
            }
        } catch (const UnknownExchangeTypeException&) {
throw Exception(QPID_MSG("Invalid exchange type: " << exchangeType));
        }
"

but the binding just has

"
bind(binding.queue, binding.exchange, binding.key, arguments, userId, connectionId);
"

Which looks like the reason adding duplicate bindings doesn't cause the broker to barf, but trying to add queues/exchanges with the same name does.

Thanks again for your response, it helped my sanity a bit - which was much needed considering the weirdness I came across this weekend trying to map things between the C++ and Java Brokers, I definitely think there's a lot of scope for "unification" there :-)

Frase


On 11/03/13 09:52, Gordon Sim wrote:
On 03/10/2013 07:25 PM, Fraser Adams wrote:

would anyone be able to confirm that "exchange-type" has never
*actually* needed to be set in a QMF create binding call?

Yes, I can confirm that is the case. The type of exchange never needs to be specified as it is implied by the exchange instance which is identified by name. I agree the code you quoted is a confusing in that regard, I suspect it has just been a bit of sloppy cut-and-paste.

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to