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 » WebSphere Message Broker (ACE) Support » TDS Problem

Post new topic  Reply to topic
 TDS Problem « View previous topic :: View next topic » 
Author Message
vallu
PostPosted: Tue May 25, 2004 8:42 pm    Post subject: TDS Problem Reply with quote

Apprentice

Joined: 29 Jun 2002
Posts: 31

I am getting the following error.

MTI. Not all the buffer was used when reading message

I am using WMQI2.1 + CSD06 on Windows 2000.

My Message definition is like this:
--------------------------------------
<Element ident='COMP_COL1_I' type='str' ></Element>
<Element ident='COMP_COL2_I' type='str' ></Element>
<Element ident='COMP_COL3_I' type='str' ></Element>

<Type ident='COMP_I_CT' composition='Sequence' typeContent='Closed' delimiter='||' dataElemSep='VarDelim'>
<Element ref='COMP_COL1_I'/>
<Element ref='COMP_COL2_I'/>
<Element ref='COMP_COL3_I'/>
</Type>

<Type ident='COMP_I_CT_EL_CT' composition='Sequence' typeContent='Closed' delimiter='<LF>' dataElemSep='AllDelim'>
<Element ident='COMP_I_CT_EL' type='COMP_I_CT' repeat="10000" maxOccurs="10000"/>
</Type>

<Message ident='COMP_I_MSG' type='COMP_I_CT_EL_CT' />
--------------------------------------------------------------------------

Output CT is a CWF with a similar structure.
I get a problem when I send an following input

abc||efg||hkg<LF>
abc||efg||hkg<LF>
||||hkg<LF>
abc||efg||hkg<LF>

The following works

abc||efg||hkg<LF>
abc||efg||hkg<LF>
||||hkg<LF>

Please suggest some approach.

Vallu


Error detail:
----------------
<Text>Caught exception and rethrowing</Text>
<Catalog>WMQIv210</Catalog>
<Severity>3</Severity>
<Number>2230</Number>
<ParserException>
<File>F:\build\S210_BP\src\cpi\pwf\tds\tdsworker.cpp</File>
<Line>287</Line>
<Function>CTDSWorker::hasNext</Function>
<Type></Type>
<Name></Name>
<Label></Label>
<Text>TDS General Error</Text>
<Catalog>WMQIv210</Catalog>
<Severity>3</Severity>
<Number>5421</Number>
<Insert>
<Type>5</Type>
<Text>COMP_I_MSG</Text>
</Insert>
<Insert>
<Type>5</Type>
<Text>/COMP_I_MSG</Text>
</Insert>
<Insert>
<Type>2</Type>
<Text>32</Text>
</Insert>
<ParserException>
<File>F:\build\S210_BP\src\MTI\MTIforBroker\MtiImbParser2\MtiImbFIHandler.cpp</File>
<Line>438</Line>
<Function>MtiImbFIHandler::endMessageContent</Function>
<Type></Type>
<Name></Name>
<Label></Label>
<Text>MTI. Not all the buffer was used when reading message</Text>
<Catalog>WMQIv210</Catalog>
<Severity>3</Severity>
<Number>5288</Number>
<Insert>
<Type>5</Type>
<Text></Text>
</Insert>
--------------------------
Back to top
View user's profile Send private message
vallu
PostPosted: Wed May 26, 2004 2:22 am    Post subject: Reply with quote

Apprentice

Joined: 29 Jun 2002
Posts: 31

Is this a bug?
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed May 26, 2004 3:56 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Not likely.

"Not all the buffer was used" means that the message set told the parser that it had a complete message, and the parser still had bits left over.

So it's likely that your message set doesn't match your input data properly. Most likely you don't have repeating fields defined correctly.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
vallu
PostPosted: Wed May 26, 2004 5:57 am    Post subject: Reply with quote

Apprentice

Joined: 29 Jun 2002
Posts: 31

Thanks Jeff. We use TDS a lot in our project, and we have found this problem with each of the message sets, which would work properly except in the above mentioned scenario.

I have tried recreating the message sets, but of no use.

Vallu
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed May 26, 2004 6:53 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

vallu wrote:
I have tried recreating the message sets, but of no use.


Well, if the message set isn't right to start off, recreating it wouldn't fix it either.

You're sure that your message set handles repeats properly? That is, if you don't put in the record with the missing fields, then it can match any number of complete records?

You're sure that your fields are properly optional?

What does a trace of the two different inputs look like?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
vallu
PostPosted: Wed May 26, 2004 7:38 am    Post subject: Reply with quote

Apprentice

Joined: 29 Jun 2002
Posts: 31

Jeff,

The message set handles the repeating groups properly, as expected. In other words, these are working message sets.

I have the trace files in my office comp. I can send it later.

You were referring to "optional" fields in the earlier email. Please explain if I can specify some field as optional.

My explanation of the problem scenario is like this.

If my input message set has 3 elements, delimited by '@' in a repeating group like:

1@2@3<CR><LF>
4@5@5<CR><LF>
3@3@4<CR><LF>

The above would succeed.

, the following sample would fail...
1@2@3<CR><LF>
@@5<CR><LF>
3@3@4<CR><LF>

In the above <CR><LF> is the repeating element delimiter.

Please observe the failing sample carefully.
It has two null values for the first 2 elements in the second row, and then there is a third row
3@3@4<CR><LF> after that.

This sample is failing. My observation is that if there are "n-1" null values
in "n" elements, it would fail to proceed further.
In my above example, n is 3.

MRM would be blank in the trace node, as below:

1(
(0x1000000)Properties = (
(0x3000000)MessageSet = 'E0FRJP4076001'
(0x3000000)MessageType = 'MSG'
(0x3000000)MessageFormat = 'TDS1'
(0x3000000)Encoding = 546
(0x3000000)CodedCharSetId = 437
(0x3000000)Transactional = TRUE
(0x3000000)Persistence = FALSE
(0x3000000)CreationTime = GMTTIMESTAMP '2004-02-01 15:20:20.950'
(0x3000000)ExpirationTime = -1
(0x3000000)Priority = 0
(0x3000000)ReplyIdentifier = X'000000000000000000000000000000000000000000000000'
(0x3000000)ReplyProtocol = 'MQ'
(0x3000000)Topic = NULL
)
(0x1000000)MQMD = (
(0x3000000)SourceQueue = 'OUT'
(0x3000000)Transactional = TRUE
(0x3000000)Encoding = 546
(0x3000000)CodedCharSetId = 437
(0x3000000)Format = ' '
(0x3000000)Version = 2
(0x3000000)Report = 0
(0x3000000)MsgType = 8
(0x3000000)Expiry = -1
(0x3000000)Feedback = 0
(0x3000000)Priority = 0
(0x3000000)Persistence = 0
(0x3000000)MsgId = X'414d5120514d342020202020202020206d141d4020000805'
(0x3000000)CorrelId = X'000000000000000000000000000000000000000000000000'
(0x3000000)BackoutCount = 0
(0x3000000)ReplyToQ = ' '
(0x3000000)ReplyToQMgr = 'QM '
(0x3000000)UserIdentifier = 'db2admin '
(0x3000000)AccountingToken = X'0000000000000000000000000000000000000000000000000000000000000000'
(0x3000000)ApplIdentityData = 'test '
(0x3000000)PutApplType = 11
(0x3000000)PutApplName = 'D:\ih03\rfhutilc.exe'
(0x3000000)PutDate = DATE '2004-02-01'
(0x3000000)PutTime = GMTTIME '15:20:20.950'
(0x3000000)ApplOriginData = ' '
(0x3000000)GroupId = X'000000000000000000000000000000000000000000000000'
(0x3000000)MsgSeqNumber = 1
(0x3000000)Offset = 0
(0x3000000)MsgFlags = 0
(0x3000000)OriginalLength = -1
)
(0x1000021)MRM = (

-------------------------------------

Please help.

Vallu
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed May 26, 2004 7:45 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Okay, let's be clear.

Do you want the TDS set to parse

||||hkg<LF>

or

@@5<CR><LF>

and accept both as valid records?

If so, then you need to indicate that the first two records are optional. This is done differently in version 2.x and version 5 - but basically you say that it can occur 0 or more times.

If you don't want these two things to be valid records, with the "missing" fields, then you need to set the occurance of all the fields to be one or more - and then accept that the parser is going to object when you ask it to validate a record that has missing fields.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
vallu
PostPosted: Wed May 26, 2004 8:02 am    Post subject: Reply with quote

Apprentice

Joined: 29 Jun 2002
Posts: 31

Jeff,

Just to be clear on my above posts,

The following is "||" delimited record with <LF> as the repeating element delimiter
||||hkg<LF>

or

Since the above record is confusing to look at, I used '@' as the delimiter
with <CR><LF> as the repeating element delimiter.

@@5<CR><LF>

BUT BOTH THE ABOVE ARE NOT PART OF A SINGLE MESSAGE. They are two different messages all together.

Please forget about ||||hkg<LF>

Just to confirm, please use

1@2@3<CR><LF>
@@5<CR><LF>
3@3@4<CR><LF>

as the sample. In the second record above, two elements have null values. Our program shall always send three elements per record. The elements could be having null values, as in above. The sample should fail. I mean the TDS should give an error.


My Message definition is like this:
--------------------------------------
<Element ident='COMP_COL1_I' type='str' ></Element>
<Element ident='COMP_COL2_I' type='str' ></Element>
<Element ident='COMP_COL3_I' type='str' ></Element>

<Type ident='COMP_I_CT' composition='Sequence' typeContent='Closed' delimiter='@' dataElemSep='VarDelim'>
<Element ref='COMP_COL1_I'/>
<Element ref='COMP_COL2_I'/>
<Element ref='COMP_COL3_I'/>
</Type>

<Type ident='COMP_I_CT_EL_CT' composition='Sequence' typeContent='Closed' delimiter='<CR><LF>' dataElemSep='AllDelim'>
<Element ident='COMP_I_CT_EL' type='COMP_I_CT' repeat="10000" maxOccurs="10000"/>
</Type>

<Message ident='COMP_I_MSG' type='COMP_I_CT_EL_CT' />
---------------------------------

Please help.
Vallu
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed May 26, 2004 8:23 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

I understood that they were not the same message.

So, you want it to throw an error if the fields are not populated.

Then set the minimum occurances of all the fields in the compound type to 1 - so that the fields are required.

BUT, this will mean that the ENTIRE MQSeries message will fail if any record has missing fields.

If you want to avoid this, you will have to set the fields to be optional, and then handle the records with missing fields yourself.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
vallu
PostPosted: Wed May 26, 2004 4:22 pm    Post subject: Reply with quote

Apprentice

Joined: 29 Jun 2002
Posts: 31

I want to define the fields in the compound type as optional, so that I could handle the null values in my ESQL code.

But, when I send a message like

1@2@3<CR><LF>
@@5<CR><LF>
3@3@4<CR><LF>

Following your suggestion, I have defined elements with min occurances as "0".

It still does not help.

Vallu
Back to top
View user's profile Send private message
vallu
PostPosted: Thu May 27, 2004 3:42 am    Post subject: Reply with quote

Apprentice

Joined: 29 Jun 2002
Posts: 31

I am treating this as an unknown problem and we have a workaround for this.

This could be useful for someone with the same problem.

Always make sure that your first element is a non null value. That solved the problem for us.

Vallu
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 » WebSphere Message Broker (ACE) Support » TDS Problem
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.