473,698 Members | 2,271 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

consuming Perl ws, WDSL namespace problem

I've been tasked with consuming a Perl web service that was written by a
person in a different department of my company. The problem is it's the
guy's first attempt at web services and he doesn't know how to create the
WDSL. I created web service with Visual Studio that mimics his service and
after some tweaking of the soapAction in the WSDL I'm able to call his
service successfully. When I use SOAPScope to look the messages being sent
and received the data is there although my response objects are always null
and I think it's a namespace problem. The Perl web service seems to return a
random namespace every time. If you look at the getURLResponse node in the
XML below you see that the namespace is 'namesp4' and this is different
every time. Is there anyway to change the WSDL to accommodate this? I've
also pasted the WSDL below Any help would be greatly appreciated!

Thanks

RESPONSE:

<?xml version="1.0" encoding="UTF-8"?>

<SOAP-ENV:Envelope xmlns:xsi="http ://www.w3.org/1999/XMLSchema-instance"
xmlns:SOAP-ENC="http://schemas.xmlsoap .org/soap/encoding/"
xmlns:SOAP-ENV="http://schemas.xmlsoap .org/soap/envelope/"
xmlns:xsd="http ://www.w3.org/1999/XMLSchema"
SOAP-ENV:encodingSty le="http://schemas.xmlsoap .org/soap/encoding/">

<SOAP-ENV:Body>

<namesp4:getURL Response xmlns:namesp4=" urn:/SOAP_URLList">

<url>

<profile xsi:type="xsd:s tring">custom1</profile>

<position xsi:type="xsd:i nt">1</position>

<action xsi:type="xsd:i nt">1</action>

<url xsi:type="xsd:s tring">http://www.ebay.com</url>

<id xsi:type="xsd:i nt">124</id>

<enabled xsi:type="xsd:i nt">1</enabled>

</url>

</namesp4:getURLR esponse>

</SOAP-ENV:Body>

</SOAP-ENV:Envelope>

REQUEST:

<?xml version="1.0" encoding="utf-8"?>

<soap:Envelop e xmlns:soap="htt p://schemas.xmlsoap .org/soap/envelope/"
xmlns:xsi="http ://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http ://www.w3.org/2001/XMLSchema">

<soap:Body>

<getURL xmlns="urn:/SOAP_URLList">

<id>124</id>

</getURL>

</soap:Body>

</soap:Envelope>

WSDL:

<?xml version="1.0" encoding="utf-8"?>

<wsdl:definitio ns xmlns:http="htt p://schemas.xmlsoap .org/wsdl/http/"
xmlns:soap="htt p://schemas.xmlsoap .org/wsdl/soap/"
xmlns:s="http://www.w3.org/2001/XMLSchema"
xmlns:soapenc=" http://schemas.xmlsoap .org/soap/encoding/"
xmlns:tns="urn:/SOAP_URLList"
xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/"
xmlns:mime="htt p://schemas.xmlsoap .org/wsdl/mime/"
xmlns:wsdl="htt p://schemas.xmlsoap .org/wsdl/"
targetNamespace ="urn:/SOAP_URLList">

<wsdl:types>

<s:schema elementFormDefa ult="qualified"
targetNamespace ="urn:/SOAP_URLList">

<s:element name="addURL">

<s:complexTyp e>

<s:sequence>

<s:element minOccurs="0" maxOccurs="1"
name="profile" type="s:string"/>

<s:element minOccurs="0" maxOccurs="1"
name="url" type="s:string"/>

<s:element minOccurs="1" maxOccurs="1"
name="action" type="s:int"/>

<s:element minOccurs="1" maxOccurs="1"
name="position" type="s:int"/>

<s:element minOccurs="1" maxOccurs="1"
name="enabled" type="s:int"/>

</s:sequence>

</s:complexType>

</s:element>

<s:element name="addURLRes ponse">

<s:complexTyp e>

<s:sequence>

<s:element minOccurs="1" maxOccurs="1"
name="addURLRes ult" type="s:int"/>

</s:sequence>

</s:complexType>

</s:element>

<s:element name="updateURL ">

<s:complexTyp e/>

</s:element>

<s:element name="updateURL Response">

<s:complexTyp e>

<s:sequence>

<s:element minOccurs="1" maxOccurs="1"
name="updateURL Result" type="s:int"/>

</s:sequence>

</s:complexType>

</s:element>

<s:element name="getURL">

<s:complexTyp e>

<s:sequence>

<s:element minOccurs="1" maxOccurs="1"
name="id" type="s:int"/>

</s:sequence>

</s:complexType>

</s:element>

<s:element name="getURLRes ponse">

<s:complexTyp e>

<s:sequence>

<s:element minOccurs="1" maxOccurs="1"
name="getURLRes ult" type="tns:url"/>

</s:sequence>

</s:complexType>

</s:element>

<s:complexTyp e name="url">

<s:sequence>

<s:element minOccurs="0" maxOccurs="1"
name="profile" type="s:string"/>

<s:element minOccurs="0" maxOccurs="1"
name="action" type="s:string"/>

<s:element minOccurs="0" maxOccurs="1"
name="url" type="s:string"/>

<s:element minOccurs="1" maxOccurs="1"
name="id" type="s:int"/>

<s:element minOccurs="1" maxOccurs="1"
name="enabled" type="s:int"/>

</s:sequence>

</s:complexType>

<s:element name="delURL">

<s:complexTyp e/>

</s:element>

<s:element name="delURLRes ponse">

<s:complexTyp e>

<s:sequence>

<s:element minOccurs="1" maxOccurs="1"
name="delURLRes ult" type="s:int"/>

</s:sequence>

</s:complexType>

</s:element>

<s:element name="listURLs" >

<s:complexTyp e/>

</s:element>

<s:element name="listURLsR esponse">

<s:complexTyp e>

<s:sequence>

<s:element minOccurs="0" maxOccurs="1"
name="listURLsR esult" type="tns:Array OfUrl"/>

</s:sequence>

</s:complexType>

</s:element>

<s:complexTyp e name="ArrayOfUr l">

<s:sequence>

<s:element minOccurs="0" maxOccurs="unbo unded"
name="url" type="tns:url"/>

</s:sequence>

</s:complexType>

</s:schema>

</wsdl:types>

<wsdl:message name="addURLSoa pIn">

<wsdl:part name="parameter s" element="tns:ad dURL"/>

</wsdl:message>

<wsdl:message name="addURLSoa pOut">

<wsdl:part name="parameter s" element="tns:ad dURLResponse"/>

</wsdl:message>

<wsdl:message name="updateURL SoapIn">

<wsdl:part name="parameter s" element="tns:up dateURL"/>

</wsdl:message>

<wsdl:message name="updateURL SoapOut">

<wsdl:part name="parameter s" element="tns:up dateURLResponse "/>

</wsdl:message>

<wsdl:message name="getURLSoa pIn">

<wsdl:part name="parameter s" element="tns:ge tURL"/>

</wsdl:message>

<wsdl:message name="getURLSoa pOut">

<wsdl:part name="parameter s" element="tns:ge tURLResponse"/>

</wsdl:message>

<wsdl:message name="delURLSoa pIn">

<wsdl:part name="parameter s" element="tns:de lURL"/>

</wsdl:message>

<wsdl:message name="delURLSoa pOut">

<wsdl:part name="parameter s" element="tns:de lURLResponse"/>

</wsdl:message>

<wsdl:message name="listURLsS oapIn">

<wsdl:part name="parameter s" element="tns:li stURLs"/>

</wsdl:message>

<wsdl:message name="listURLsS oapOut">

<wsdl:part name="parameter s" element="tns:li stURLsResponse"/>

</wsdl:message>

<wsdl:portTyp e name="SOAP_URLL istSoap">

<wsdl:operati on name="addURL">

<wsdl:input message="tns:ad dURLSoapIn"/>

<wsdl:output message="tns:ad dURLSoapOut"/>

</wsdl:operation>

<wsdl:operati on name="updateURL ">

<wsdl:input message="tns:up dateURLSoapIn"/>

<wsdl:output message="tns:up dateURLSoapOut"/>

</wsdl:operation>

<wsdl:operati on name="getURL">

<wsdl:input message="tns:ge tURLSoapIn"/>

<wsdl:output message="tns:ge tURLSoapOut"/>

</wsdl:operation>

<wsdl:operati on name="delURL">

<wsdl:input message="tns:de lURLSoapIn"/>

<wsdl:output message="tns:de lURLSoapOut"/>

</wsdl:operation>

<wsdl:operati on name="listURLs" >

<wsdl:input message="tns:li stURLsSoapIn"/>

<wsdl:output message="tns:li stURLsSoapOut"/>

</wsdl:operation>

</wsdl:portType>

<wsdl:binding name="SOAP_URLL istSoap" type="tns:SOAP_ URLListSoap">

<soap:binding style="document "
transport="http ://schemas.xmlsoap .org/soap/http"/>

<wsdl:operati on name="addURL">

<soap:operati on soapAction="urn :/SOAP_URLList#ad dURL"
style="document "/>

<wsdl:input>

<soap:body use="literal"/>

</wsdl:input>

<wsdl:output>

<soap:body use="literal"/>

</wsdl:output>

</wsdl:operation>

<wsdl:operati on name="updateURL ">

<soap:operati on soapAction="urn :/SOAP_URLList#up dateURL"
style="document "/>

<wsdl:input>

<soap:body use="literal"/>

</wsdl:input>

<wsdl:output>

<soap:body use="literal"/>

</wsdl:output>

</wsdl:operation>

<wsdl:operati on name="getURL">

<soap:operati on soapAction="urn :/SOAP_URLList#ge tURL"
style="document "/>

<wsdl:input>

<soap:body use="literal"/>

</wsdl:input>

<wsdl:output>

<soap:body use="literal"/>

</wsdl:output>

</wsdl:operation>

<wsdl:operati on name="delURL">

<soap:operati on soapAction="urn :/SOAP_URLList#de lURL"
style="document "/>

<wsdl:input>

<soap:body use="literal"/>

</wsdl:input>

<wsdl:output>

<soap:body use="literal"/>

</wsdl:output>

</wsdl:operation>

<wsdl:operati on name="listURLs" >

<soap:operati on soapAction="urn :/SOAP_URLList#li stURLs"
style="document "/>

<wsdl:input>

<soap:body use="literal"/>

</wsdl:input>

<wsdl:output>

<soap:body use="literal"/>

</wsdl:output>

</wsdl:operation>

</wsdl:binding>

<wsdl:service name="SOAP_URLL ist">

<documentatio n xmlns="http://schemas.xmlsoap .org/wsdl/"/>

<wsdl:port name="SOAP_URLL istSoap"
binding="tns:SO AP_URLListSoap" >

<soap:address location="http://eng-dev:9000"/>

</wsdl:port>

</wsdl:service>

</wsdl:definition s>

TEST CODE:

Dim ws As New SOAP_URLList.SO AP_URLList

Try

Dim url As SOAP_URLList.ur l = ws.getURL(124)

Dim sf As New _

Serialization.X mlSerializer(Ge tType(SOAP_URLL ist.url))

Dim sXML As StringWriter = _

New StringWriter(Ne w System.Text.Str ingBuilder)

sf.Serialize(sX ML, url)

Me.txtResponse. Text = sXML.ToString

Catch ex As SoapException

MsgBox(ex.ToStr ing)

Me.txtResponse. Text = ex.ToString

End Try

Returns:

<?xml version="1.0" encoding="utf-16"?>

<url xmlns:xsd="http ://www.w3.org/2001/XMLSchema"
xmlns:xsi="http ://www.w3.org/2001/XMLSchema-instance" xsi:nil="true" />
Dec 20 '05 #1
0 2369

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1745
by: bob | last post by:
I have been trying to auto generate a proxy from a WSDL file. I do this fairly regularly, so I am not a novice, but perhaps I am missing something easy. I searched on the problem, but did not find too much that was helpful... I am trying to tie into the web services offered by a large firm. They have a basic set of methods I was able to integrate easily into my project using the tried and true "auto generate the proxy method". The...
0
1958
by: bob | last post by:
I have been trying to auto generate a proxy from a WSDL file. I do this fairly regularly, so I am not a novice, but perhaps I am missing something easy. I searched on the problem, but did not find too much that was helpful... I am trying to tie into the web services offered by a large firm. They have a basic set of methods I was able to integrate easily into my project using the tried and true "auto generate the proxy method". The...
5
2318
by: MR | last post by:
I apologize in advance for re-asking a question that I posed before. I understand a little more than i did before and I am posing 2 specific questions: I need to write an application that sends orders to a non-Windows web service. 1) I received DTD files for the SOAP messages that I need to send. I was able to convert them to XSD files. Upon examination of the files it is apparent that the XSD does not match the database in any way. so...
3
4833
by: Neter Smith | last post by:
I have run into a problem when trying to import a WSDL reference under VS 2003 and 1.1 of the framework. It appears as if it is in the generation of the proxy that things are failing. When I add the reference, I get the following error: C:\Inetpub\wwwroot\WebServices\samples\WSDL\dotnet\OblixSampleForDotNetWSDL\Web References\localhost\Reference.map(1): Custom tool error: Unable to import WebService/Schema. A schema with the namespace...
3
6503
by: Matt D | last post by:
I've got two web services that use the same data types and that clients will have to consume. I read the msdn article on sharing types (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnservice/html/service07162002.asp) but I don't want clients to have to add two web references and then manually have to edit the proxy classes. After doing some searching I found that putting references to multiple web services in a .disco...
1
3426
by: leslie_tighe | last post by:
Hello, I have webservice created with Axis 1.2.1 and that I am trying to consuming in .NET (VB) using the Microsoft provided tools. While I am able to consume methods on the service that return simple type, I cannot consume methods that return complex objects. I have tried experimenting, with this, but am at a bit of loss on where the problem lies. When I call the services from a browser, I do get back the response that contains valid...
3
3051
by: Ben Crinion | last post by:
Hi im having a few problems consuming a SOAP::Lite web service. I think the problem is actually with the WSDL but im not sure. I have a SOAP::Lite client which works ok using the WSDL (which i defined by hand). The .NET client on the other hand does not work at all and i get this error when i send the request. Failed to access class (2001::XMLSchema): syntax error at (eval 91) line 1, near "require 2001"
3
6095
by: Jeremy Chapman | last post by:
I've writtin a very simple web service in axis which returns an array of classes. I consume it in a .net app. When receiving the response, my .net app generates an error "Cannot assign object of type System.Object to an object of type PersonWS.WorkGroupData.". I've included the wsdl of the consumed axis web service, the request/responses of the web service by the .net app and the exception and stack trace. Hoping someone can tell me...
1
2446
by: Paul van Brouwershaven | last post by:
Hi All, I'm struggling with the WDSL restrictions in PHP/SOAP for a while know. I would like to create some simple restrictions in my WDSL file. The script are running both on the same server with PHP Version 5.2.6 with the official soap extension. On both my client and server there is some error configuration:
0
8674
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9157
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9028
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8895
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8861
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6518
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5860
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
3046
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2001
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.