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 Index » IBM MQ Java / JMS » JMS client and non-JMS RFH Format field

Post new topic  Reply to topic
 JMS client and non-JMS RFH Format field « View previous topic :: View next topic » 
Author Message
vmcgloin
PostPosted: Tue Feb 18, 2003 7:49 am    Post subject: JMS client and non-JMS RFH Format field Reply with quote

Knight

Joined: 04 Apr 2002
Posts: 560
Location: Scotland

Hi,

We have JMS client apps that go to non-JMS servers. This all works fine, until we want to do an MQGET call with the MQGMO_CONVERT option. This fails because the MQRFH Format field contains nulls.

We need to keep the RFH because we send the message via MQSI, so the option of setting targetClient to NONJMS is no good. The 'MQ Using Java' contains info about the mapping of RFH fields to JMS properties for the Format field, but not what I am looking for.

Can anyone share how to ensure that the JMS client sets the MQRFH Format field to either blanks or 'MQSTR '?

Thanks,
Vicky
Back to top
View user's profile Send private message
kingdon
PostPosted: Wed Feb 19, 2003 3:33 am    Post subject: Reply with quote

Acolyte

Joined: 14 Jan 2002
Posts: 63
Location: UK

Hi Vicky,

What CCSID are you trying to convert into, and what error code is being returned from the failing GET?

Regards,
James.
Back to top
View user's profile Send private message
vmcgloin
PostPosted: Wed Feb 19, 2003 4:01 am    Post subject: Reply with quote

Knight

Joined: 04 Apr 2002
Posts: 560
Location: Scotland

Hi James,

We are just doing a get with convert on the queue because it contains messages from various sources - Web (JMS), Mainframe (non-JMS) etc.
The messages causing problems do not actually need converted. They have an MQMD CCSID of 1208, and an MQHRF CCSID of 819. We are running this on AIX so the conversion is to 819.

Examining the problem message shows that the RFH Format field is 8 nulls instead of the 8 spaces that I might have expected.

This is part of the output from the getting application and only applies to the JMS messages (strangely it seems to have a 0 reason code with a warning return code) -
Quote:
AMQ6188: The system could not dynamically load the shared library
'/var/mqm/exits/' due to a problem with the library. The errno was 13 and the
error message was 'The file access permissions do not allow the specified
action.'. The queue manager will continue without this library.
Msg(7) CompCode => 1, Reason => 0
MQGET failed: CompCode => 1, Reason => 0


And from the AMQERR01.LOG -
Quote:
-------------------------------------------------------------------------------
19/02/03 11:38:45
AMQ6174: The library /var/mqm/exits/_r was not found. The queue manager will
continue without this module.

EXPLANATION:
The dynamically loadable file /var/mqm/exits/_r was not found.
ACTION:
Check that the file exists and is either fully qualified or is in the
appropriate directory.
-------------------------------------------------------------------------------
19/02/03 11:38:45
AMQ6174: The library /var/mqm/exits/MQHRF_r was not found. The queue manager
will continue without this module.

EXPLANATION:
The dynamically loadable file /var/mqm/exits/MQHRF_r was not found.
ACTION:
Check that the file exists and is either fully qualified or is in the
appropriate directory.
-------------------------------------------------------------------------------
19/02/03 11:44:41
AMQ6188: The system could not dynamically load the shared library
'/var/mqm/exits/' due to a problem with the library. The errno was 13 and the
error message was 'The file access permissions do not allow the specified
action.'. The queue manager will continue without this library.

EXPLANATION:
This message applies to AIX, HP-UX and Linux systems. The shared library
'/var/mqm/exits/' failed to load correctly due to a problem with the library.
ACTION:
Check that the library exists and is in the correct place with the correct file
permissions etc. and has not been corrupted.
-------------------------------------------------------------------------------


Thanks for your time!
Vicky
Back to top
View user's profile Send private message
kingdon
PostPosted: Wed Feb 19, 2003 6:14 am    Post subject: Reply with quote

Acolyte

Joined: 14 Jan 2002
Posts: 63
Location: UK

Hi,

I'm getting out of my depth here, so I'll have to find some people to get advice off. I know there are a couple of questions they'll immediately ask me, so I'd better check those first:

a) It looks like you are using JMS to publish a message to MQSI, with the TopicConnectionFactory.brokerVersion set to JMSC.MQJMS_BROKER_V1. Is this true?

b) Is there any other transformation of the message within MQSI, or is it sent straight out to the subscriber?

c) What version of MQ are you using for the queue manager which is doing the get-convert, which version of MQSI, and which version of the MQ JMS classes are being used for sending the message?

I suspect that, given the complexity of the problem, it may be best if you raise a problem with the support team who will be better placed to work through this issue with you. In the mean time, if I get any ideas I'll let you know!

Cheers,
James.
Back to top
View user's profile Send private message
vmcgloin
PostPosted: Wed Feb 19, 2003 6:24 am    Post subject: Reply with quote

Knight

Joined: 04 Apr 2002
Posts: 560
Location: Scotland

Thanks James.
It is not important enough for us to raise a pmr yet (it just came up when a colleague wrote some admin scripts), so don't waste anymore of your time on it!
The problem does not really involve conversion or MQSI (just how the RFH Format field is set from JMS), but I appreciate that there probably is not a simple answer, so thanks for your input anyway.

Cheers,
Vicky
Back to top
View user's profile Send private message
kingdon
PostPosted: Wed Feb 19, 2003 6:42 am    Post subject: Reply with quote

Acolyte

Joined: 14 Jan 2002
Posts: 63
Location: UK

Hi Vicky,

I just had a chat with the local expert on conversion, and it certainly sounds like an 'interesting' problem. To make progress on it we would need detailed trace information and a full message dump, so it would take considerable effort at your end, and need to go through formal support to keep it well managed from our end. I understand if this isn't worth your while at the moment. I'll see if I can prod a few people to think about it

Cheers,
James.
Back to top
View user's profile Send private message
PeterPotkay
PostPosted: Wed Feb 19, 2003 5:23 pm    Post subject: Reply with quote

Poobah

Joined: 15 May 2001
Posts: 7722

I haven't actually coded in JMS, but the JAVA manual states the following on the last page of Chapter 12:

Quote:

The MQRFH2.format field is set as follows:
MQFMT_NONE
for ObjectMessage, BytesMessage, or messages with no body.
MQFMT_STRING
for TextMessage, StreamMessage, or MapMessage.



Can your JMS apps set this field right before the PUT?
_________________
Peter Potkay
Keep Calm and MQ On
Back to top
View user's profile Send private message
vmcgloin
PostPosted: Thu Feb 20, 2003 1:30 am    Post subject: Reply with quote

Knight

Joined: 04 Apr 2002
Posts: 560
Location: Scotland

Peter,

I read this as the JMS/MQ code sets the MQRFH2.Format field as MQFMT_NONE when the message is a bytes message, rather than the application code...?

MQFMT_NONE 'bbbbbbbb'
MQFMT_STRING 'MQSTRbbb'

Maybe it is a problem, maybe not. I'll look into it more at some point and maybe raise it with IBM formally.

Vicky
Back to top
View user's profile Send private message
kingdon
PostPosted: Thu Feb 20, 2003 3:04 am    Post subject: Reply with quote

Acolyte

Joined: 14 Jan 2002
Posts: 63
Location: UK

Yes, that's right. The JMS layer will set the RFH2.format according to the message type being sent. However, the picture is confused because there can be three different formats in some messages produced by MQJMS. From the preceding posts, it looks like this is a pub-sub style message sent using a brokerVersion of V1 and with targetClient of JMS. I'd expect such a message to have:
an MQMD.format of MQHRF
an MQRFH.format of MQHRF2
and an MQRFH2.format of either MQSTR or blanks (for format_none).

There are other possibilities; setting targetClient to non-JMS will eliminate the RFH2. Setting brokerVersion to V2 would eliminate the RFH, replacing it with an RFH2 which would be combined with the 'normal' JMS RFH2 if present, and using point to point instead of pub-sub removes the need for an RFH/RFH2 publish header.

Of course, if any of the the header format fields contains MQFMT_NONE then the get with convert will fail, so the original problem will always arise for certain JMS message types. This may explain the original observation, but I'm still curious where the nulls crept in...

Cheers,
James.
Back to top
View user's profile Send private message
vmcgloin
PostPosted: Thu Feb 20, 2003 5:07 am    Post subject: Reply with quote

Knight

Joined: 04 Apr 2002
Posts: 560
Location: Scotland

Please forget this thread!!!
The eCommerce guys here are using a wrapper that creates their own generated RFH1 header at the front of the text of the message, so MQJMS treats it as part of the msg body. TargetClient is set to non-JMS so MQJMS does not create a header. The Format field is therefore entirely under the control of the guys writing the wrapper code here.

Thanks everyone, and sorry for wasting your time.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ Java / JMS » JMS client and non-JMS RFH Format field
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.