qpid-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From meh...@cs.man.ac.uk
Subject Re: Java Client - Question
Date Sun, 15 Jun 2008 12:52:59 GMT
Hi All,

Thank you Rajith and Ted for your help.

Arnaud as we discussed, I was looking at the 
org.apache.qpidity.nclient.impl.ClientSession to create a client session 
and I found there are several programs are misssing in "transport api" 
(this is the cause of several errors). Could you please point me where I 
can find these APIs? For instance following set of programs are missing:

import org.apache.qpidity.transport.MessageAcceptMode;
import org.apache.qpidity.transport.MessageAcquireMode;
import org.apache.qpidity.transport.Option;
import org.apache.qpidity.transport.DeliveryProperties;
import org.apache.qpidity.transport.MessageProperties;
import org.apache.qpidity.transport.ConnectionClose;
import org.apache.qpidity.transport.ConnectionCloseCode;
import org.apache.qpidity.transport.ConnectionCloseOk;

I am checking out from here:
http://svn.apache.org/repos/asf/incubator/qpid/trunk


Can anybody help me in this? 

Thank you.

Regards,
Rahul

On Jun 12 2008, Ted Ross wrote:

> Rajith Attapattu wrote:
> > On Thu, Jun 12, 2008 at 6:18 AM, <mehtar@cs.man.ac.uk> wrote:
> >
> >   
> >> Hi All,
> >>
> >> Thanks Carl for giving me a good starting point. So I am focusing on 
> >> the first step from the following step (regarding JMX/WSDM Bridge 
> >> project):
> >>
> >> 1. Creating a Java Client which can talk to Qpid C++ Broker. Thus I can
> >> fetch the schema out from the broker
> >>
> >> 2. Once I will get the schema, I will translate it into JMS object
> >>
> >> 3. Then, we can expose those to WSDM
> >>
> >> One question on the first step, I am creating an individual Java 
> >> Client for this. I dont really understand how I will bind Queue of my 
> >> Java client to exchange so that I can receive messages and updates 
> >> periodically from the exchange. Carl, did you want me to create an 
> >> individual java client, if so how can I bind it with the exchange?
> >>
> >> Secondly, will I use the Client APIs of Qpid broker to make the 
> >> connection and create/declare queues and bind them to exchange?
> >>
> >> For instance, I did find the APIs for the same under this directory
> >> structure:
> >>
> >>
> >>  
> >>  
> >> https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid/java/client/example/src/main/java/org/apache/qpid/example/amqpexample/
> >>     
> >
> >
> > I wrote them a while back and haven't looked at them recently. These 
> > examples compile so I assume it reflects the latests AMQP java API.
> >
> > However if you are not doing any management specific commands and only 
> > wants to bind to an exchange and receive messages, maybe you can get 
> > away with JMS.
> >
> > Regards,
> >
> > Rajith
> >
> >   
> Rahul,
> 
> For your purposes, you need to create two private queues.  The first, 
> the "management" queue, must be bound to the topic exchange called 
> "qpid.management" with a binding key of "mgmt.#".  The second, the 
> "reply" queue, must be bound to amq.direct with a binding key that is 
> identical to the name of the queue.
> 
> You will then be sending messages to the "qpid.management" exchange and 
> receiving messages from both private queues.
> 
> You can use the JMS API for message transfer.  You will need the AMQP 
> codec from the non-JMS Java API to encode and decode the bodies of the 
> management messages.
> 
> -Ted
> 
> 

Mime
View raw message