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 » Namespace decl in Message Broker Flow

Post new topic  Reply to topic
 Namespace decl in Message Broker Flow « View previous topic :: View next topic » 
Author Message
rcrippen
PostPosted: Fri Nov 14, 2008 7:17 am    Post subject: Namespace decl in Message Broker Flow Reply with quote

Apprentice

Joined: 01 Aug 2002
Posts: 45
Location: Rochester, NY

I was wondering if anyone has seen a way around this particular issue that I'm trying to resolve:
I have a Message Broker V6.0.8 Windows platform invoking an IIS webservice/.NET interface. This interface is being created by an off-shore third party company.

The SOAP envelope and Body are being properly created, but when I try to create the namespace declaration to match the .NET WebService requirements, the Message Broker throws exceptions. The Broker is complaining about no namespace identifier.

The namespace declaration for the root element that I'm trying to build which has been communicated to me is in the following form:

<TagName xmlns="http://tempuri.org/">

When I try to build this element with the namespace identifier that I've normally seen required, the webservice returns a SOAP Fault indicating it can't find the object instance.

On other namespace declarations in a webservice call, I've had to build the namespace in the following manner:
<ns:TagName xmlns:ns="http://tempuri.org/">

Has anyone seen a way (in Message Broker) to build the tag element with the namespace without an identifier?

Thanks,
Rob
Back to top
View user's profile Send private message Visit poster's website
elvis_gn
PostPosted: Fri Nov 14, 2008 7:41 am    Post subject: Reply with quote

Padawan

Joined: 08 Oct 2004
Posts: 1905
Location: Dubai

Hi rcrippen,

You need to create the namespace as the 'default namespace'. Search the forum, you'll find sample code, else paste your namespace declaration code.

Regards.
Back to top
View user's profile Send private message Send e-mail
kimbert
PostPosted: Fri Nov 14, 2008 8:46 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

elvis_gn is 100% correct. However, as this confuses a lot of people, here's the full answer...
Quote:
Has anyone seen a way (in Message Broker) to build the tag element with the namespace without an identifier?
Each element/attribute in the message tree has a namespace URI. It does not have a namespace prefix. When the message tree is written out ( usually when you hit an output node ) the broker's XML parser walks the message tree, detects the namespace declarations ( xmlns attributes ), and assigns the correct namespace prefix to each tag in the output XML.
So you simply need to put the correct namespace declaration in the message tree.
Back to top
View user's profile Send private message
rcrippen
PostPosted: Fri Nov 14, 2008 11:37 am    Post subject: Reply with quote

Apprentice

Joined: 01 Aug 2002
Posts: 45
Location: Rochester, NY

Thanks to the postings by previous members, I was able to get this to work. It was a little tricky and it doesn't work quite the same if you are using an XMLNSC domain versus an XMLNS domain.

The main key point is that you must define the Properties.MessageDomain to be 'XMLNS' (not XML). :)
Back to top
View user's profile Send private message Visit poster's website
kimbert
PostPosted: Fri Nov 14, 2008 1:36 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Glad you got it working.
re: this comment
Quote:
The main key point is that you must define the Properties.MessageDomain to be 'XMLNS' (not XML)
Two comments:
- You should not use the XML domain for new message flows. It is deprecated. XMLNSC is the one to use if you want good performance and features when you upgrade.
- The parser which serializes the message tree is not identified by Properties.MessageDomain. It is the parser which is associated with the root node of the message tree. In many cases, that root node is the last child of OutputRoot, ( e.g. OutputRoot.XMLNS or OutputRoot.XMLNSC ). I expect this will provoke you into explaining what you meant
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 » Namespace decl in Message Broker Flow
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.