On 18 February 2014 01:11, Mark Barker <mark.bar...@shaw.ca> wrote:

> Robbie,
> thanks again for your answers.
>
> As for your first suggestion:
>
> "connecting an ActiveMQ JMS client to the ActiveMQ
> broker and a Qpid JMS client to the Qpid broker within the same JVM"
>
> Is this going to be possible in practice? I'm something of a novice at
> Java too. Will there be some kind of conflict if trying to use both the
> ActiveMQ JMS client and the Qpid JMS client APIs in the same process? How
> would/could this be done (example build command)? Thus far I have been
> building simple example code from the command line and referencing the
> relevant .jar dependency in the classpath params for both javac (build) and
> java (runtime).
>
>
There shouldn't be an issue as long as there are no conflicts between the
dependencies of the ActiveMQ client and the Qpid client.  The Qpid clients
aim to have as few dependencies as possible, so there really shouldn't be
an issue.


> Finally,
> today I've been looking at getting the simple Hello.java example running
> on the ActiveMQ broker.
> Obviously, this means I have to use a JMS AMQP 1.0 client, so I've been
> using the Qpid JMS 1.0 client.
> I've encountered some issues which seem to relate to the Connection URL
> syntax from the JNDI (hello.properties) file.
>
> For instance,
> in a previous Qpid client talking AMQP 0-10 with a Qpid broker, I used:
> amqp://username:password@clientid/test?brokerlist='tcp://localhost:5672'
> however I've read and seen in practice that this won't work with the 1.0
> client.
> Instead I have to use something like:
> amqp://username:password@localhost:5672
>
> Can somebody please point me to the relevant documentation that explains
> this difference in syntax. For all my digging on the Qpid website, I can
> only find examples of the first/former (0-10 style), with no disclaimers or
> caveats regarding the 1.0 client.
>
>
No - there isn't a lot (or indeed really any) documentation around the AMQP
1.0 client.  As you've noted the syntax is a little different from the 0-10
style... but you've pretty much got all of the syntax already.

There are currently a number of options (set in the normal URI way:
amqp://username:password@host:port?option1=value1&option2=value2...)   to
fine tune some AMQP settings.  If you are interested you can look in the
code which parses them here:

https://svn.apache.org/viewvc/qpid/trunk/qpid/java/amqp-1-0-client-jms/src/main/java/org/apache/qpid/amqp_1_0/jms/impl/ConnectionFactoryImpl.java?revision=1557982&view=markup&pathrev=1568703

Between lines 295 and 381 you will see the available options defined along
with a brief description of their purpose.


> In addition, I've found I can use "queue://" or "topic://" prefixes in the
> JNDI properties to specify the object type when using the generic interface
> (i.e. general instead of p2p/pub-sub). Is that syntax a feature of the AMQP
> protocol, or something specific to the Qpid client or ActiveMQ broker? I
> can't find much mention of it anywhere.
>
>
That's something specific to the ActiveMQ broker.


> Thanks again for giving these questions your attention!!
>
>
>
-- Rob


>
> -----Original Message----- From: Robbie Gemmell
> Sent: Saturday, February 15, 2014 2:57 PM
>
> To: users@qpid.apache.org
> Subject: Re: New User JMS API Questions
>
> On 14 February 2014 04:55, Mark Barker wrote:
>
>  If anyone has a tried this, or can confirm:
>> will it be possible to have a JMS client using an ActiveMQ broker on one
>> machine (or maybe a producer/consumer pair), ultimately sending a message
>> which then routes to a Qpid broker and associated local JMS consumer on a
>> second machine (preserving all standard and application-specific JMS
>> message headers/properties). Has this been done and are there further
>> tricks, considerations and caveats here?
>> Maybe the ActiveMQ JMS consumer process on the first machine makes the
>> routing decision and then places the message via a producer instance for
>> the Qpid broker on the 2nd machine?
>>
>
> It sounds like you are talking about bridging two brokers, which you
> presumably do either by connecting an ActiveMQ JMS client to the ActiveMQ
> broker and a Qpid JMS client to the Qpid broker within the same JVM, or by
> using the Qpid AMQP 1.0 JMS client to connect to both brokers.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@qpid.apache.org
> For additional commands, e-mail: users-h...@qpid.apache.org
>
>

Reply via email to