On Thu, Jun 12, 2008 at 2:54 AM, adisesha <[EMAIL PROTECTED]> wrote: > Hi, > > > > Thanks for sending mail, actually I was out of office. > > > > Here is my requirement (captured in user list). > > > > I am looking for WebsphereMQseries + Axis2 service with JMS + tomcat. > > > > When I put message in to queue in MQSeries, automatically that should call > Axis2 service & then return the result of service to another queue. That's > it. > > Provided that the Axis2 service is configured to listen on that particular queue, the service should invoked when a message is sent to the queue.
> > > For this can you give me sample of Axis2.xml, services.xml, any client > program to put message in to queue. > The following link clearly explains how you can configure the axis2.xml and services.xml with any messaging provider. http://ws.apache.org/axis2/1_4/jms-transport.html In summary, in axis2.xml you need to uncomment the JMS transport and then specify the initialContextFactory and JNDI provider URL for MQSeries. Please consult the MQSeries documentation to find out what they are. As for services.xml you don't really need to make any changes unless you want to specify a custom destination or want the service to start specifically on certain transports etc. The above link explains all that. As for sending messages to the queue, any sample JMS code should do the trick. All you need to do is to a) lookup your connection factory ConnectionFactory conFac = (ConnectionFactory)ctx.lookup("jndi_name"); b) create connection Connection con = conFac.createConnection() c) create a session Session con = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);connection.createSession(false, Session.AUTO_ACKNOWLEDGE); d) look up a destination Destination destination = (Destination)ctx.lookup("directQueue"); - this is the destination the service is listening to e) create a MessageProducer MessageProducer messageProducer = session.createProducer(destination); f) create a message and send it, Message message = session.createTextMessage("xxxxxxx"); messageProducer.send(message); Hope this helps. Regards, Rajith > > Let me know if I am not very clear > > > > Many Thanks > > > ------------------------------ > > *From:* Rajith Attapattu [mailto:[EMAIL PROTECTED] > *Sent:* Tuesday, June 10, 2008 8:34 PM > *To:* [email protected]; [EMAIL PROTECTED] > *Subject:* Re: Sample i/p message for Axis2 JMS > > > > adisesha, > > I saw a couple of emails from you on the user list about a JMS transport > issue. > Can you please explain what you are trying to achieve? > What JMS provider are you using? > If so what are the errors/exceptions you are seeing? > > Regards, > > Rajith > > On Mon, Jun 9, 2008 at 9:10 AM, adisesha <[EMAIL PROTECTED]> > wrote: > > Hi, > > > > Can some one provide me the sample i/p message or Client program to put > message in to Message Queue. I have almost tried all combinations. > > > > Thanks in advance > > > ------------------------------ > > *From:* adisesha [mailto:[EMAIL PROTECTED] > *Sent:* Sunday, June 08, 2008 1:04 PM > *To:* '[email protected]' > *Subject:* Sample i/p message for Axis2 JMS > > > > Hi, > > > > While working on Axis2 services with JMS I am getting "Exception in thread > "JMSWorker-1" java.lang.NullPointerException ". I don't see any suggestions > for this, so started debugging Axis2 engine. I realized the issue is with > expected input message. When I added outMessage*.setJMSReplyTo(outQueue)*in > client program; then this issue is fixed, & do have exception else where > at msgContext.setEnvelope(JMSUtils.*getSOAPEnvelope*(message, msgContext, > in)); -- NullPointerException. > > > > I have 2 issues here. > > 1. Adding <parameter name="transport.jms.ReplyDestination" > locked="true">Testme</parameter> in services.xml /& axis2.xml is not > considered in JMSMessageReceiver.java ( *if* (replyTo == *null*) > {Parameter param = msgContext.getAxisService().getParameter(JMSConstants.* > REPLY_PARAM*);) why is it expecting client message to have "outMessage* > .setJMSReplyTo(outQueue);**" * Any suggestions on this please. > > 2. Can you provide me sample Client program to put message with all > JMS constants required for JMSMessageReceiver. I have almost spent more than > 2 weeks to fix these issues. > > > > Note: "Addressing" is disabled, as I don't know/see the use of it in my > case. > > > > Thanks in advance > > Disclaimer > > The information contained in this communication is intended solely for the > use of the individual or entity to whom it is addressed and others > authorized to receive it. It may contain confidential or legally privileged > information. If you are not the intended recipient you are hereby notified > that any disclosure, copying, distribution or taking any action in reliance > on the contents of this information is strictly prohibited and may be > unlawful. If you have received this communication in error, please notify us > immediately by forwarding this email to [EMAIL PROTECTED] and then delete > it from your system. Ness technologies is neither liable for the proper and > complete transmission of the information contained in this communication nor > for any delay in its receipt. > > > > > -- > Regards, > > Rajith Attapattu > Red Hat > http://rajith.2rlabs.com/ > -- Regards, Rajith Attapattu Red Hat http://rajith.2rlabs.com/
