Author |
Message
|
klee |
Posted: Mon Oct 06, 2003 12:22 am Post subject: CSQC721E Invalid MQCIH |
|
|
Novice
Joined: 05 Oct 2003 Posts: 15
|
Hi,
When I send an MQ message including an MQCIH structure to a CICS Bridge (V 5.2) on an OS/390 using JMS, I get an "CSQC721E Invalid MQCIH" error message.
Here is my MQCIH structure:
private String strucId="CIH ";
private int version=1;
private int strucLength=164; // v1 164, v2 180
private int encoding=0;
private int codedCharSetId=500;
private String format=MQC.MQFMT_NONE;
private int flags=0;
private int returnCode=0;
private int compCode=0;
private int reason=0;
private int uOWControl=273;
private int getWaitInterval=-2;
private int linkType=1;
private int outputDataLength=-1;
private int facilityKeepTime=0;
private int aDSDescriptor=0;
private int conversationalTask=0;
private int taskEndStatus=0;
private byte[] facility=new byte[8];
private String function=" ";
private String abendCode=" ";
private String authenticator=" ";
private String reserved1=" ";
private String replyToFormat=MQC.MQFMT_NONE;
private String remoteSysId=" ";
private String remoteTransId=" ";
private String transactionId="RQM1";
private String facilityLike=" ";
private String attentionId=" ";
private String startCode=" ";
private String cancelCode=" ";
private String nextTransactionId=" ";
private String reserved2=" ";
private String reserved3=" ";
// for version 2
private int cursorPosition=0;
private int errorOffset=0;
private int inputItem=0;
private int reserved4=0;
Is there something wrong with my MQCIH structure?
Cheers,
Klee |
|
Back to top |
|
 |
bower5932 |
Posted: Mon Oct 06, 2003 10:07 am Post subject: |
|
|
 Jedi Knight
Joined: 27 Aug 2001 Posts: 3023 Location: Dallas, TX, USA
|
Try posting the output of amqsbcg rather than the code you used to build the header. There might be something that amqsbcg would show you that actually indicates what is wrong. |
|
Back to top |
|
 |
RogerLacroix |
Posted: Mon Oct 06, 2003 8:24 pm Post subject: |
|
|
 Jedi Knight
Joined: 15 May 2001 Posts: 3264 Location: London, ON Canada
|
Hi,
Post the rest of your code. i.e. writeString() & writeInt()
You probably messed up of some of the String length fields (some are 4 bytes, while others are 8 bytes).
Don't forget, you need to take care of any blank padding.
later
Roger... _________________ Capitalware: Transforming tomorrow into today.
Connected to MQ!
Twitter |
|
Back to top |
|
 |
klee |
Posted: Tue Oct 07, 2003 12:34 am Post subject: |
|
|
Novice
Joined: 05 Oct 2003 Posts: 15
|
Here is what I m trying to do.
Java(JMS)<-> MQ V5.3(AIX) <-> MQ V5.2(OS/390) <-> CICS DPL Bridge <-> Trancsaction Code <-> CICS Program
And I get the following return message from CICS Bridge.
"CIH MQSTR CSQC721E Invalid MQCIH CKBR0000085" |
|
Back to top |
|
 |
klee |
Posted: Tue Oct 07, 2003 12:38 am Post subject: |
|
|
Novice
Joined: 05 Oct 2003 Posts: 15
|
I can't get a message content from a queue which is on my OS/390 MQ server, so I send a message to a queue which is on my AIX MQ Server and get the following output by running amqsbcg.
****Message descriptor****
StrucId : 'MD ' Version : 2
Report : 0 MsgType : 1
Expiry : -1 Feedback : 0
Encoding : 785 CodedCharSetId : 500
Format : 'MQCICS '
Priority : 4 Persistence : 0
MsgId : X'414D51204D512E54412E5554444441533F82163C20002F01'
CorrelId : X'414D51214E45575F53455353494F4E5F434F5252454C4944'
BackoutCount : 0
ReplyToQ : 'Q.T.O001.REPLY '
ReplyToQMgr : 'MQ.TA.UTDDAS1 '
** Identity Context
UserIdentifier : 'mqm '
AccountingToken :
X'0332303400000000000000000000000000000000000000000000000000000006
ApplIdentityData : ' '
** Origin Context
PutApplType : '28'
PutApplName : ' '
PutDate : '20031007' PutTime : '07522213'
ApplOriginData : ' '
GroupId : X'000000000000000000000000000000000000000000000000'
MsgSeqNumber : '1'
Offset : '0'
MsgFlags : '0'
OriginalLength : '-1'
**** Message ****
length - 393 bytes
00000000: 4349 4820 0000 0001 0000 00A4 0000 01F4 'CIH .......?..?
00000010: 0000 0311 4D51 5354 5220 2020 0000 0000 '....MQSTR ....'
00000020: 0000 0000 0000 0000 0000 0000 0000 0111 '................'
00000030: FFFF FFFE 0000 0001 0000 07D0 0000 0000 '?......?...
00000040: 0000 0000 0000 0000 0000 0000 0000 0000 '................'
00000050: 0000 0000 2020 2020 2020 2020 2020 2020 '.... '
00000060: 2020 2020 2020 2020 2020 2020 4D51 5354 ' MQST'
00000070: 5220 2020 2020 2020 2020 2020 5251 4D4A 'R RQMJ'
00000080: 2020 2020 2020 2020 2020 2020 2020 2020 ' '
00000090: 2020 2020 2020 2020 2020 2020 2020 2020 ' '
000000A0: 2020 2020 545A 5251 4D4A 5020 3030 3054 ' TZRQMJP 000T'
000000B0: 4453 2039 3236 3820 5444 4953 3031 2020 'DS 9268 TDIS01 '
000000C0: 5251 4D4A 2041 4354 6D73 6743 6F64 3030 'RQMJ ACTmsgCod00'
000000D0: 3130 3031 3030 314B 5744 5530 3030 3031 '1001001KWDU00001'
000000E0: 3032 3032 2030 3031 2020 2020 2020 2020 '0202 001 '
000000F0: 2020 2020 2020 3030 3020 2020 2020 2020 ' 000 '
00000100: 2020 2020 2020 2030 3030 2020 2020 2020 ' 000 '
00000110: 2020 2020 2020 2020 3030 3020 2020 2020 ' 000 '
00000120: 2020 2020 2020 2020 2030 3030 2020 2020 ' 000 '
00000130: 2020 2020 2020 2020 2020 3030 3020 2020 ' 000 '
00000140: 2020 2020 2020 2020 2020 2030 3030 2020 ' 000 '
00000150: 2020 2020 2020 2020 2020 2020 3030 3020 ' 000 '
00000160: 2020 2020 2020 2020 2020 2020 2030 3030 ' 000'
00000170: 2020 2020 2020 2020 2020 2020 2020 3030 ' 00'
00000180: 3054 414E 2020 3030 30 '0TAN 000 '
Last edited by klee on Tue Oct 07, 2003 12:40 am; edited 1 time in total |
|
Back to top |
|
 |
klee |
Posted: Tue Oct 07, 2003 12:39 am Post subject: |
|
|
Novice
Joined: 05 Oct 2003 Posts: 15
|
Here is the code for building my MQCIH.
MQCIH mqCIH=new MQCIH();
mqCIH.setTransactionId("RQMJ");
mqCIH.setStrucId("CIH ");
mqCIH.setVersion(1);
mqCIH.setStrucLength(164);
mqCIH.setCodedCharSetId(785);
mqCIH.setEncoding( 500 );
mqCIH.setOutputDataLength(229);
outMessage.writeBytes( mqCIH.getStrucId().getBytes() );
outMessage.writeInt( mqCIH.getVersion() );
outMessage.writeInt( mqCIH.getStrucLength() );
outMessage.writeInt( mqCIH.getEncoding() );
outMessage.writeInt( mqCIH.getCodedCharSetId() );
outMessage.writeBytes( mqCIH.getFormat().getBytes() );
outMessage.writeInt( mqCIH.getFlags() );
outMessage.writeInt( mqCIH.getReturnCode() );
outMessage.writeInt( mqCIH.getCompCode() );
outMessage.writeInt( mqCIH.getReason() );
outMessage.writeInt( mqCIH.getUOWControl() );
outMessage.writeInt( mqCIH.getGetWaitInterval() );
outMessage.writeInt( mqCIH.getLinkType() );
outMessage.writeInt( mqCIH.getOutputDataLength() );
outMessage.writeInt( mqCIH.getFacilityKeepTime() );
outMessage.writeInt( mqCIH.getADSDescriptor() );
outMessage.writeInt( mqCIH.getConversationalTask() );
outMessage.writeInt( mqCIH.getTaskEndStatus() );
outMessage.writeBytes( mqCIH.getFacility() );
outMessage.writeBytes( mqCIH.getFunction().getBytes() );
outMessage.writeBytes( mqCIH.getAbendCode().getBytes() );
outMessage.writeBytes( mqCIH.getAuthenticator().getBytes() );
outMessage.writeBytes( mqCIH.getReserved1().getBytes() );
outMessage.writeBytes( mqCIH.getReplyToFormat().getBytes() );
outMessage.writeBytes( mqCIH.getRemoteSysId().getBytes() );
outMessage.writeBytes( mqCIH.getRemoteTransId().getBytes() );
outMessage.writeBytes( mqCIH.getTransactionId().getBytes() );
outMessage.writeBytes( mqCIH.getFacilityLike().getBytes() );
outMessage.writeBytes( mqCIH.getAttentionId().getBytes() );
outMessage.writeBytes( mqCIH.getStartCode().getBytes() );
outMessage.writeBytes( mqCIH.getCancelCode().getBytes() );
outMessage.writeBytes( mqCIH.getNextTransactionId().getBytes() );
outMessage.writeBytes( mqCIH.getReserved2().getBytes() );
outMessage.writeBytes( mqCIH.getReserved3().getBytes() );
outMessage.writeBytes(tempStr.getBytes());
queueSender.send(outMessage); |
|
Back to top |
|
 |
bob_buxton |
Posted: Tue Oct 07, 2003 4:26 am Post subject: |
|
|
 Master
Joined: 23 Aug 2001 Posts: 266 Location: England
|
It appears from your message dump that the Message is in ASCII but you have specified that the character set of the message is EBCDIC.
Quote: |
Encoding : 785 CodedCharSetId : 500 |
So the OS/390 queue manager decides no conversion is needed and then the bridge sees that CIH string (still in ASCII) does not match the value it was expecting and issues the message.
You should specify the CCSID and Encoding to be MQCCSI_Q_MGR and MQENC_NATIVE and then allow the receiving Q manager do the conversion to host representation. You will probably also need to specify the CONVERT attribute on the channel back from the OS/390 to have the reply message converted back to ASCII.
Alternatively you could do all the conversions in your application which would be more work. _________________ Bob Buxton
Ex-Websphere MQ Development
Last edited by bob_buxton on Wed Oct 08, 2003 12:06 am; edited 1 time in total |
|
Back to top |
|
 |
klee |
Posted: Tue Oct 07, 2003 7:01 pm Post subject: |
|
|
Novice
Joined: 05 Oct 2003 Posts: 15
|
Thanks.
My problem is solved after I convert the MQCIH and my message to EBCDIC. |
|
Back to top |
|
 |
|