ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum IndexWebSphere Message Broker SupportWeblogic MQ integration

Post new topicReply to topic
Weblogic MQ integration View previous topic :: View next topic
Author Message
ninjahatodi
PostPosted: Tue Jan 02, 2018 1:59 am Post subject: Weblogic MQ integration Reply with quote

Novice

Joined: 02 Apr 2009
Posts: 12

We are replacing websphere application server with weblogic in our existing application. This J2EE application used to send MQ message to another application. On WAS there is setting in Resources-> JMS -> Queue -> Select configured Queue Name - > Advanced Properties -> Message Format -> Apply RFH version 2 header to message sent to this Destination -> Message Body -> MQ. This ensures message is sent in MQSTR format to destination.

What is similar setting we can do in Weblogic to deliver this message in MQSTR format ?

Is there any way we can set this thing in java program so don't have to depend on settings at application server ?

We have already tried following options
2. (MQQueue) responseQueueInfo.setTargetClient(1);
1. (TextMessage) textMessage.setStringProperty("JMS_IBM_Format", "MQSTR");

I would really appericiate any help as there is not much i could get on google.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Tue Jan 02, 2018 3:31 am Post subject: Re: Weblogic MQ integration Reply with quote

Grand Poobah

Joined: 18 Nov 2003
Posts: 19727
Location: LI,NY

ninjahatodi wrote:
We are replacing websphere application server with weblogic in our existing application. This J2EE application used to send MQ message to another application. On WAS there is setting in Resources-> JMS -> Queue -> Select configured Queue Name - > Advanced Properties -> Message Format -> Apply RFH version 2 header to message sent to this Destination -> Message Body -> MQ. This ensures message is sent in MQSTR format to destination.

What is similar setting we can do in Weblogic to deliver this message in MQSTR format ?

Is there any way we can set this thing in java program so don't have to depend on settings at application server ?

We have already tried following options
2. (MQQueue) responseQueueInfo.setTargetClient(1);
1. (TextMessage) textMessage.setStringProperty("JMS_IBM_Format", "MQSTR");

I would really appreciate any help as there is not much i could get on google.

Neither option should be necessary.
The sending party should determine the JMSReplyTo destination. At that point the Destination should already have been "decorated with that information" (example)
Code:
Session.createQueue("queue:///<queuename>?targetClient=1");

This would then be passed when you set the Destination from the JMSReplyTo...
As for the format, just the fact that you are using a TextMessage should set the JMS_IBM_Format to MQConstants.MQFMT_STRING (which is not the same as "MQSTR" but more like "MQSTR "....
Don't forget to create the response message as a text message
Code:
TextMessage respmsg = session.createTextMessage();


Hope this helps
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
zpat
PostPosted: Tue Jan 02, 2018 3:45 am Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5650
Location: UK

You can set the target as non-JMS in several ways, including in the Java code, or in the MQ URI.
_________________
Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error.
Back to top
View user's profile Send private message
ninjahatodi
PostPosted: Thu Jan 04, 2018 11:40 pm Post subject: Re: Weblogic MQ integration Reply with quote

Novice

Joined: 02 Apr 2009
Posts: 12

fjb_saper wrote:
ninjahatodi wrote:
We are replacing websphere application server with weblogic in our existing application. This J2EE application used to send MQ message to another application. On WAS there is setting in Resources-> JMS -> Queue -> Select configured Queue Name - > Advanced Properties -> Message Format -> Apply RFH version 2 header to message sent to this Destination -> Message Body -> MQ. This ensures message is sent in MQSTR format to destination.

What is similar setting we can do in Weblogic to deliver this message in MQSTR format ?

Is there any way we can set this thing in java program so don't have to depend on settings at application server ?

We have already tried following options
2. (MQQueue) responseQueueInfo.setTargetClient(1);
1. (TextMessage) textMessage.setStringProperty("JMS_IBM_Format", "MQSTR");

I would really appreciate any help as there is not much i could get on google.

Neither option should be necessary.
The sending party should determine the JMSReplyTo destination. At that point the Destination should already have been "decorated with that information" (example)
Code:
Session.createQueue("queue:///<queuename>?targetClient=1");

This would then be passed when you set the Destination from the JMSReplyTo...
As for the format, just the fact that you are using a TextMessage should set the JMS_IBM_Format to MQConstants.MQFMT_STRING (which is not the same as "MQSTR" but more like "MQSTR "....
Don't forget to create the response message as a text message
Code:
TextMessage respmsg = session.createTextMessage();


Hope this helps

Quote:
Session.createQueue("queue:///<queuename>?targetClient=1");
This does not work. We are already using TextMessage. Any thing else we might be mising?
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Fri Jan 05, 2018 10:59 am Post subject: Reply with quote

Grand Poobah

Joined: 18 Nov 2003
Posts: 19727
Location: LI,NY

Please define does not work... Are the cryer monkeys coming a howling??
What was the expect result, what was the effective result?

Yes there is a setting in the connection factory related to targetClient which tells it to keep the targetClient of the calling party....

But apart from that no..., unless you are doing something very unorthodoxal....
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
ninjahatodi
PostPosted: Mon Jan 08, 2018 3:12 am Post subject: Reply with quote

Novice

Joined: 02 Apr 2009
Posts: 12

fjb_saper wrote:
Please define does not work... Are the cryer monkeys coming a howling??
What was the expect result, what was the effective result?

Yes there is a setting in the connection factory related to targetClient which tells it to keep the targetClient of the calling party....

But apart from that no..., unless you are doing something very unorthodoxal....


Quote:
You are answering question you think I am asking and not the one being asked. I want you to get that setting targetClient did not had desired effect of sending the data in MQSTR format. We were able to send the data in MQSTR format with below settings.
com.ibm.mq.jms.MQQueue("queue://XXXXXXXX.RQ?persistence=-1&targetClient=1");

Hope you get it and you get gotten by it.
Back to top
View user's profile Send private message
Display posts from previous:
Post new topicReply to topic Page 1 of 1

MQSeries.net Forum IndexWebSphere Message Broker SupportWeblogic MQ integration
Jump to:



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP


Theme by Dustin Baccetti
Powered by phpBB 2001, 2002 phpBB Group

Copyright MQSeries.net. All rights reserved.