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 » Broker 7.0.0.5 not parsing XML?

Post new topic  Reply to topic
 Broker 7.0.0.5 not parsing XML? « View previous topic :: View next topic » 
Author Message
wbinewbie
PostPosted: Thu May 16, 2013 1:40 pm    Post subject: Broker 7.0.0.5 not parsing XML? Reply with quote

Novice

Joined: 24 Dec 2012
Posts: 11

Hi , wondering if anyone noticed this issue, we upgraded brokr to 7.0.0.5 recently and after that it dosent seem to be parsing XML, even though the debugger shows the XML tree.

In more detail, at the start of the compute node, I am copying OutputRoot=InputRoot and when provided a well-formed XML as input (that opens in IE), If I check if OutputRoot.XMLNSC IS NOT NULL or InputRoot.XMLNSC IS NOT NULL, the checks fail...

anyone see this strange behaviour?
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu May 16, 2013 2:00 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

If you suspect something like this, the obvious next steps are:
1. Insert a Trace node after the input node
2. Take a debug-level user trace and read it carefully.

The most likely reason for this that you have specified Parse Timing as 'On demand' on the input node, and your message flow logic is not triggering any parsing at all. This is as-designed.
Back to top
View user's profile Send private message
wbinewbie
PostPosted: Thu May 16, 2013 2:29 pm    Post subject: Reply with quote

Novice

Joined: 24 Dec 2012
Posts: 11

looks like the issue is that my incoming xml has namespace specified. how do i handle namespaces in broker. Do i need to model the message?
Back to top
View user's profile Send private message
rekarm01
PostPosted: Thu May 16, 2013 2:44 pm    Post subject: Re: Broker 7.0.0.5 not parsing XML? Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 1415

wbinewbie wrote:
If I check if OutputRoot.XMLNSC IS NOT NULL or InputRoot.XMLNSC IS NOT NULL, the checks fail...

What exactly are these checks supposed to be checking for?

InputRoot.XMLNSC and OutputRoot.XMLNSC are typically NAME elements that won't have a value, so "IS NOT NULL" would return FALSE, whether the elements exist or not, and whether the elements have child elements or not.

wbinewbie wrote:
looks like the issue is that my incoming xml has namespace specified. how do i handle namespaces in broker. Do i need to model the message?

What happens exactly, when the "incoming xml has namespace specified"? What problem does this cause? The XMLNSC parser should be able to handle XML messages with namespaces, with or without an associated schema.
Back to top
View user's profile Send private message
Vitor
PostPosted: Fri May 17, 2013 4:01 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

wbinewbie wrote:
how do i handle namespaces in broker.


Same way you handle any other XML artififact.

wbinewbie wrote:
Do i need to model the message?


Not need, but you must at least account for the namespaces.

I agree with my associate; what are you trying to do? Whatever it is, that code probably won't do it.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
new2z
PostPosted: Fri May 17, 2013 12:46 pm    Post subject: Reply with quote

Novice

Joined: 16 May 2013
Posts: 15

@@wbinewbie

you may want to use browse to these sections from the infocenter corresponding to your broker version. Not that the way you work with namespaces will change between versions.

1. Developing message flow applications > Transforming messages > Using ESQL > Writing ESQL > Manipulating messages in the XML domains > Manipulating messages in the XMLNSC domain > The message body


2. Developing message flow applications > Transforming messages > Using ESQL > Writing ESQL > Manipulating messages in the XML domains > Working with XML messages

Thanks
Back to top
View user's profile Send private message
wbinewbie
PostPosted: Sun May 19, 2013 1:09 pm    Post subject: Reply with quote

Novice

Joined: 24 Dec 2012
Posts: 11

I am just trying to do simple operations such as existence of a tag or value of a certain tag in XML. What i see is that it works fine in the case of XML inout messages that dint have a namespace defined in the opening tag - i.e xmlns=... but fails when the message has a namespace defined..
Back to top
View user's profile Send private message
wbinewbie
PostPosted: Sun May 19, 2013 1:35 pm    Post subject: Reply with quote

Novice

Joined: 24 Dec 2012
Posts: 11

so for example, if I have :

Quote:

<StartTag xmlns="urn:iso:std:iso:20022:tech:xsd:setr" xmlns:t="http://www.w3.org/namespace/">
<Tag1>34566775</Tag1>
<Tag2>123456</Tag2>
</StartTag>


How do i check for existence or values of Tag1 and Tag2?
Back to top
View user's profile Send private message
McueMart
PostPosted: Mon May 20, 2013 12:31 am    Post subject: Reply with quote

Chevalier

Joined: 29 Nov 2011
Posts: 490
Location: UK...somewhere

Code:

IF EXISTS(InputRoot.XMLNSC.*:StartTag.*:Tag1) THEN
   ...
END IF


I'm wildcarding the namespace above but you can reference particular ones if you want (look it up in the infocenter).
Back to top
View user's profile Send private message
kimbert
PostPosted: Mon May 20, 2013 12:48 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Put in those Trace nodes, as suggested in my last post.
Read the topics - they really do contain useful information.

Post again when you have done both of those things.
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 » Broker 7.0.0.5 not parsing XML?
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.