Author |
Message
|
Chouan |
Posted: Thu Sep 13, 2007 7:35 am Post subject: Bug for the first message after a flow deployement |
|
|
Newbie
Joined: 13 Sep 2007 Posts: 3
|
In my flow, I have a Java compute node. This is an extract of the code:
Code: |
MbOutputTerminal out = getOutputTerminal("out");
MbOutputTerminal alt = getOutputTerminal("alternate");
MbMessage inMessage = assembly.getMessage();
MbMessage outMessage = new MbMessage(inMessage);
MbMessageAssembly outAssembly = new MbMessageAssembly(assembly,outMessage);
MbElement mqmdHeader = outAssembly.getMessage().getRootElement().getFirstChild().getNextSibling();
mqmdHeader.detach();
MbMessage msg = outAssembly.getMessage();
byte[] bitstream = msg.getBuffer();
// ...
|
When I deploy the flow, I have always a problem with the first message I put in the flow. The "msg.getBuffer();" line throws an Exception:
Code: |
[BIPv600:5347]BIP5347E: MtiImbParser2: RM has thrown an unknown exception.
Returned by the RM when an unknown exception is thrown. This is an internal error.
Shutdown and restart the message broker. If the problem continues to occur, then restart the system. If the problem still continues to occur contact your IBM support center providing system trace files where possible. : RM has thrown an unknown exception
|
This exception occurs only once, for the first message after the deployement. After that, if I put exactly the same message into the flow, everything works correctly... All the next messages works perfectly.
Somebody could tell me why this error occurs (and why only once), and how I can correct the problem?
Thanks
PS: I use WMB 6.0
PS2: if that can help, here is the WMB trace for this problem:
Code: |
******* Broker Info ************************
BrokerName : IESBK01
BrokerVersion : 6000
Plateforme : UNIX
ProcessId : 159854
BrokerUserId : wmbi
ExecutionGroupLabel : EG2
ExecutionGroupName : b27ecd21-1401-0000-0080-81b4d3f2c155
BrokerDataSource : IESDB99
QueueManagerName : YLAI0006B
WorkPath : /var/mqsi
**********************************************
----- BrokerExceptionList -----------------------------
(
(0x01000000):RecoverableException = (
(0x03000000):File = '/build/S000_P/src/DataFlowEngine/ImbDataFlowNode.cpp'
(0x03000000):Line = 616
(0x03000000):Function = 'ImbDataFlowNode::createExceptionList'
(0x03000000):Type = 'ComIbmJniNode'
(0x03000000):Name = 'com/inetpsa/ies/idefix/compas/COMPASFluxExterneMetierIDX#FCMComposite_1_8.com/inetpsa/ies/metier/Write_To_File#FCMComposite_1_1'
(0x03000000):Label = 'com.inetpsa.ies.idefix.compas.COMPASFluxExterneMetierIDX.Write_To_File.JavaCompute'
(0x03000000):Catalog = 'BIPv600'
(0x03000000):Severity = 3
(0x03000000):Number = 2230
(0x03000000):Text = 'Node throwing exception'
(0x01000000):ParserException = (
(0x03000000):File = '/build/S000_P/src/MTI/MTIforBroker/MtiImbParser2/MtiImbRMErrorMap.cpp'
(0x03000000):Line = 170
(0x03000000):Function = 'MtiImbRMErrorMap::checkRC'
(0x03000000):Type = ''
(0x03000000):Name = ''
(0x03000000):Label = ''
(0x03000000):Catalog = 'BIPv600'
(0x03000000):Severity = 3
(0x03000000):Number = 5347
(0x03000000):Text = 'RM has thrown an unknown exception'
(0x01000000):Insert = (
(0x03000000):Type = 2
(0x03000000):Text = '12'
)
(0x01000000):Insert = (
(0x03000000):Type = 5
(0x03000000):Text = 'rmLoadDictionary'
)
(0x01000000):Insert = (
(0x03000000):Type = 5
(0x03000000):Text = 'FBQ39OS002001'
)
(0x01000000):Insert = (
(0x03000000):Type = 5
(0x03000000):Text = ''
)
)
)
)
|
Last edited by Chouan on Thu Sep 13, 2007 7:40 am; edited 1 time in total |
|
Back to top |
|
 |
jefflowrey |
Posted: Thu Sep 13, 2007 7:37 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
I think you shouldn't use getBuffer().
I think you should use toBitstream() instead. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
Chouan |
Posted: Thu Sep 13, 2007 7:45 am Post subject: |
|
|
Newbie
Joined: 13 Sep 2007 Posts: 3
|
jefflowrey wrote: |
I think you should use toBitstream() instead. |
I just tried but the "toBitStream()" method (or equivalent) doesn't exists on the "MbMessage" java object. I think this method isn't availible in WMB 6.0
Do you have another idea? |
|
Back to top |
|
 |
jefflowrey |
Posted: Thu Sep 13, 2007 8:00 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Hrm.
It's a method on MbElement, not MbMessage.
But looking at the verbiage on getBuffer in the API docs... it seems that it doesn't suffer from the problems that I thought it did - so it should maybe be okay to use.
See what happens if you call finalizeMessage() before getBuffer(). _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
Chouan |
Posted: Fri Sep 14, 2007 3:13 am Post subject: |
|
|
Newbie
Joined: 13 Sep 2007 Posts: 3
|
Thanks a lot for your response, but it doesn't work...
With the "finalizeMessage()" method, I have the same problem.
With the "toBitStream()" method, I have an Exception:
Code: |
com.ibm.broker.plugin.MbElement._toBitstream(Native Method)
com.ibm.broker.plugin.MbElement.toBitstream(MbElement.java:2221)
|
It is similar to the one I had with "getBuffer()":
Code: |
com.ibm.broker.plugin.MbMessage._getBuffer(Native Method)
com.ibm.broker.plugin.MbMessage.getBuffer(MbMessage.java:327)
|
I put a Trace Node just before the Java Node, where I print "${Root}" to determine if the first message was malformed... but the first message appears to be correct.
I put a message in the flow => Exception
I put the same message in the flow => ok
Here is the result of a "diff" command between the two messages just before the Java Node (which code is in my first post):
Code: |
Comparing: secondMSG.txt
To: firstMSG.txt
========
10
<! (0x03000000):CreationTime = GMTTIMESTAMP '2007-09-14 11:27:13.320'
!> (0x03000000):CreationTime = GMTTIMESTAMP '2007-09-14 11:26:58.060'
32
<! (0x03000000):MsgId = X'414d5120594c4149303030364220202046d1a11920030a5d'
!> (0x03000000):MsgId = X'414d5120594c4149303030364220202046d1a11920030a50'
43
<! (0x03000000):PutTime = GMTTIME '11:27:13.320'
!> (0x03000000):PutTime = GMTTIME '11:26:58.060'
|
Theses 3 differencies are normal, so I really don't understand why the second message is ok whereas the first creates this "RM unknown exception" |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Sep 14, 2007 3:54 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Open a PMR.
 _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
|