on 01-25-2007 4:15 PM
Hi,
I have a requirement where the incoming XML contains namespace prefixes that do not match the namespace prefix set on the XI definition.
Therefore the message mapping does not work !
I have seen a few thread recommending using the Anonymizer Module Processor to override the namespace prefixes.
However, I cannot seem to get this to work on an message inbound to XI - it always seems to retain the namespace prefixes of the incoming message.
I have added the followingto the module section of the SOAP adapter inbound channel:
Module name - localejbs/AF_Modules/XMLAnonymizerBean
Module type - Local Enterprise Bean
Module key - namespace
Module configuration:
Module key - namespace
Parameter name - anonymizer.acceptNamespaces
Parameter value - 'http://schemas.xmlsoap.org/soap/envelope/' ns0 'http://tempuri.org' ns0 'java:com.xerox.hc.registration.event' ns0
The incoming XML looks like this:
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
- <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
- <env:Body env:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
- <m:getRegistrationEventQueryResponse xmlns:m="http://tempuri.org/">
- <result xmlns:n1="java:com.xerox.hc.reg2.registration.event" soapenc:arrayType="n1:RegistrationEventJB[9]">
- <RegistrationEventJB xsi:type="n1:RegistrationEventJB">
- <cleanSerialNumber soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">KN0025428</string>
</cleanSerialNumber>
- <clientId soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">KN0025428</string>
</clientId>
<clientType xsi:type="xsd:string">Device</clientType>
<eventDate xsi:type="xsd:dateTime">2007-01-23T12:33:58.318-05:00</eventDate>
<eventType xsi:type="xsd:string">SerialNumberChange</eventType>
</RegistrationEventJB>
- <RegistrationEventJB xsi:type="n1:RegistrationEventJB">
- <cleanSerialNumber soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">TFN702031</string>
</cleanSerialNumber>
- <clientId soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">TFN702031</string>
</clientId>
<clientType xsi:type="xsd:string">Device</clientType>
<eventDate xsi:type="xsd:dateTime">2007-01-23T13:00:27.449-05:00</eventDate>
<eventType xsi:type="xsd:string">SerialNumberChange</eventType>
</RegistrationEventJB>
- <RegistrationEventJB xsi:type="n1:RegistrationEventJB">
- <cleanSerialNumber soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">PSG000002</string>
</cleanSerialNumber>
- <clientId soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">PSG000002</string>
</clientId>
<clientType xsi:type="xsd:string">Device</clientType>
<eventDate xsi:type="xsd:dateTime">2007-01-23T17:55:13.067-05:00</eventDate>
<eventType xsi:type="xsd:string">Deregistration</eventType>
</RegistrationEventJB>
- <RegistrationEventJB xsi:type="n1:RegistrationEventJB">
- <cleanSerialNumber soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">RKR000002</string>
</cleanSerialNumber>
- <clientId soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">RKR000002</string>
</clientId>
<clientType xsi:type="xsd:string">Device</clientType>
<eventDate xsi:type="xsd:dateTime">2007-01-23T18:53:42.629-05:00</eventDate>
<eventType xsi:type="xsd:string">Deregistration</eventType>
</RegistrationEventJB>
- <RegistrationEventJB xsi:type="n1:RegistrationEventJB">
- <cleanSerialNumber soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">RKR000002</string>
</cleanSerialNumber>
- <clientId soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">RKR000002</string>
</clientId>
<clientType xsi:type="xsd:string">Device</clientType>
<eventDate xsi:type="xsd:dateTime">2007-01-23T18:54:40.235-05:00</eventDate>
<eventType xsi:type="xsd:string">Registration</eventType>
</RegistrationEventJB>
- <RegistrationEventJB xsi:type="n1:RegistrationEventJB">
- <cleanSerialNumber soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">KMM010309</string>
</cleanSerialNumber>
- <clientId soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">KMM-010309</string>
</clientId>
<clientType xsi:type="xsd:string">ProxyDevice</clientType>
<eventDate xsi:type="xsd:dateTime">2007-01-23T19:00:56.574-05:00</eventDate>
<eventType xsi:type="xsd:string">Registration</eventType>
</RegistrationEventJB>
- <RegistrationEventJB xsi:type="n1:RegistrationEventJB">
- <cleanSerialNumber soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">DLC010061</string>
</cleanSerialNumber>
- <clientId soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">DLC0100615CA</string>
</clientId>
<clientType xsi:type="xsd:string">ProxyDevice</clientType>
<eventDate xsi:type="xsd:dateTime">2007-01-24T15:29:59.268-05:00</eventDate>
<eventType xsi:type="xsd:string">Deregistration</eventType>
</RegistrationEventJB>
- <RegistrationEventJB xsi:type="n1:RegistrationEventJB">
- <cleanSerialNumber soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">DLC010061</string>
</cleanSerialNumber>
- <clientId soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">DLC0100615CA</string>
</clientId>
<clientType xsi:type="xsd:string">ProxyDevice</clientType>
<eventDate xsi:type="xsd:dateTime">2007-01-24T15:40:37.123-05:00</eventDate>
<eventType xsi:type="xsd:string">Registration</eventType>
</RegistrationEventJB>
- <RegistrationEventJB xsi:type="n1:RegistrationEventJB">
- <cleanSerialNumber soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">TFN702031</string>
</cleanSerialNumber>
- <clientId soapenc:arrayType="xsd:string[1]">
<string xsi:type="xsd:string">TFN702031</string>
</clientId>
<clientType xsi:type="xsd:string">ProxyDevice</clientType>
<eventDate xsi:type="xsd:dateTime">2007-01-25T10:30:02.660-05:00</eventDate>
<eventType xsi:type="xsd:string">Deregistration</eventType>
</RegistrationEventJB>
</result>
</m:getRegistrationEventQueryResponse>
</env:Body>
</env:Envelope>
All namespace prefixes need to be overridden to ns0 but with the configuration I have added this is not working.
Any ideas what I am missing or have configured incorrectly ?
Kind regards
Colin.
Hi Colin,
There is no matter how the namespace prefixes are called. If you have ns0 or t is no difference.
The problem why the mapping is not working is the difference between prefixed namespaces like this:
<m:getRegistrationEventQueryResponse xmlns:m="http://tempuri.org/">
and non-prefixed namespaces like this:
<result xmlns:n1="java:com.xerox.hc.reg2.registration.event">
With the IR you can only create message types with one prefixed namesspace. It is not possible to create a message structure as you need inside the IR.
You have to create the WSDL externally and upload as external definition to the IR. Let BizTalk create the WSDL.
If this is not possible, you should XSLT for mapping.
Regards
Stefan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Stefan,
Is there any other software to create a WSDL or XSD from XML such as StylusStudio or XMLSPY that can be loaded into XI ?
There is a WSDL currently for this XML but it has arrayType definitions which are not supported by XI (it is generated from WEA Weblogic).
i need some software I can get on trial as this is a one-off exercise.
Kind regards
Colin.,
You can download a trial version of Altova XML Spy http://www.altova.com/ which you can keep 30 days.
Regards
Stefan
I have to admit that I have not created WSDL with XML Spy so far, as I have used it only to test the SOAP adapter.
But when I remember right, it is possible to upload, modify or create a WSDL with the trial version.
Check the download page for the features:
http://www.altova.com/download/xmlspy/xml_editor_enterprise.html
You need the enterprise edition for WSDL.
Stefan
Message was edited by:
Stefan Grube
Used Stefan's suggestion
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Marked incorrectly as answered
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Colin ,
Make sure that you are not using single quotes instead of apostrophes .
In case you are using single quotes you need to add anonymizer.quote and in the value enter a single quote ".Use this before any other parameter
Also check SAP Note 880173
Bipin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
I am using apostrophes so have not entered the parameter anonymizer.quote as it is not required in this case as far as I can gather.
I am using XI 3.0 on Web AS 7.00.
Is there anything else you can see missing from the namespaces I have listed in the parameters anonymizer.acceptNamespaces to set the prefix to ns0: on the inbound message ?
Is this only valid on outbound not inbound messages ?
I have followed OSS note 880173 already.
I would have expected after the changes where made and activated that the inbound message in SXI_MONITOR would show the changes.
I would also point out that this is actually a response to an initial request from XI but it is only the response back to XI I expect to change.
Any ideas where I am going wrong ?
Kind regards
Colin.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.