473,322 Members | 1,540 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

Problems using ZSI web service from .NET

Hello,

I am not sure this is the right place to ask. I tried the ZSI mailing
list, but got no response there.

My goal is to write some web services with ZSI to be used by a client
written in .NET. I'm using ZSI 1.2.7 (this was easy to install on my
Debian system).

I have no problem with functions with parameters and return values
with simple types, but I am having a hell of a time moving a simple
array.

My web service is taken from the zsi examples:

______________________________
#!/usr/bin/python

def echo(s):
return s

from ZSI import dispatch
dispatch.AsCGI()
______________________________
I want to invoke the echo function with an array of strings as a
parameter and I want it to give me an array back. I had a lot of
trouble putting together a WSDL file that was properly imported by
Visual Studio (without turning my string arrays into single strings),
but with the help of many google searches, I finally came to a
description with the following schema:

______________________________
<schema
targetNamespace="https://secure6.wwwcomm.com/admin/soap/DomainKiller/bin/DomainKiller.xsd"
xmlns="http://www.w3.org/2001/XMLSchema"

<complexType name="ArrayOfString">
<complexContent>
<restriction base="soapenc:Array">
<sequence>
<element name="item" type="string" minOccurs="0"
maxOccurs="unbounded" nillable="true"/>
</sequence>
<attribute ref="soapenc:arrayType"
wsdl:arrayType="xsd:string[]"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"/>
</restriction>
</complexContent>
</complexType>
</schema>
______________________

For brevity, I've left out the rest of the wsdl file. Messages for
parameters and return value of echo are defined as having the above
type ArrayOfString.

Now, it seems that ZSI doesn't like what my .NET client is sending it.

Request from .NET app:

______________________________________________
<?xml version="1.0" encoding="utf-8" ?>
<soap:Envelope
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:tns="https://secure6.wwwcomm.com/admin/soap/DomainKiller/bin/DomainKiller.wsdl"
xmlns:types="https://secure6.wwwcomm.com/admin/soap/DomainKiller/bin/DomainKiller.wsdl/encodedTypes"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema" >

<soap:Body soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<echo>
<s href="#id1" />
</echo>
<soapenc:Array id="id1" soapenc:arrayType="xsd:string[2]">
<Item>s1</Item>
<Item>s2</Item>
</soapenc:Array>
</soap:Body>

</soap:Envelope>
_______________________________________________

The response from the ZSI cgi:

_______________________________________________
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ZSI="http://www.zolera.com/schemas/ZSI/"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" >
<SOAP-ENV:Body>
<SOAP-ENV:Fault>
<faultcode>SOAP-ENV:Client</faultcode>
<faultstring>Unparseable message</faultstring>
<detail>
<ZSI:ParseFaultDetail>
<ZSI:string>Any cannot parse untyped element</ZSI:string>
<ZSI:trace>/soap:Envelope/soap:Body/soapenc:Array/Item[1]</ZSI:trace>
</ZSI:ParseFaultDetail>

</detail>
</SOAP-ENV:Fault>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
_________________________________________________
For comparison, a simple ZSI client works fine and this is the dialog:

_________________________________ Tue Jan 20 13:38:34 2004 REQUEST:
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ZSI="http://www.zolera.com/schemas/ZSI/"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" >
<SOAP-ENV:Body>
<echo>
<E403ee28c SOAP-ENC:arrayType="xsd:anyType[3]">
<SOAP-ENC:string id="401f8b00">1</SOAP-ENC:string>
<SOAP-ENC:string id="40219520">2</SOAP-ENC:string>
<SOAP-ENC:string id="40219560">3</SOAP-ENC:string>
</E403ee28c>
</echo>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

_________________________________ Tue Jan 20 13:38:36 2004 RESPONSE:
Date: Tue, 20 Jan 2004 18:38:35 GMT
Server: Apache/1.3.26 Ben-SSL/1.48 (Unix) Debian GNU/Linux PHP/4.1.2
mod_perl/1.26
Content-Length: 664
Content-Type: text/xml; charset="utf-8"

<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ZSI="http://www.zolera.com/schemas/ZSI/"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" >
<SOAP-ENV:Body>
<echoResponse>
<E4050908c SOAP-ENC:arrayType="xsd:anyType[3]">
<SOAP-ENC:string id="404ea950">1</SOAP-ENC:string>
<SOAP-ENC:string id="404eaa10">2</SOAP-ENC:string>
<SOAP-ENC:string id="404eaae8">3</SOAP-ENC:string>
</E4050908c>
</echoResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

_____________________________________
It seems the arguments to echo have types here.

Can I get .NET to do the same? Can this be done through the WSDL file?
Or else, how can I send arrays back and forth?

Thank you,

Michiel van Wessem
Jul 18 '05 #1
0 1678

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

Similar topics

14
by: Jim Hubbard | last post by:
Are you up to speed on the difficulties in using the 1.1 .Net framework? Not if you are unaware of the 1,596 issues listed at KBAlertz (http://www.kbalertz.com/technology_3.aspx). If you are...
32
by: jp29 | last post by:
My take on problems composing, serving and rendering XHTML documents/web pages: 1. Typical conscientious web authors are producing XHTML documents (Web pages) that feature valid Markup and with...
3
by: Andi Twine | last post by:
Hi all, I really hope someone here can help ! I have designed and built an ASP.NET web service with Visual Studio .NET. The web service outputs some dummy XML data when its called with some...
7
by: Timo Haberkern | last post by:
Hi there, i have some troubles with my TSearch2 Installation. I have done this installation as described in http://www.sai.msu.su/~megera/oddmuse/index.cgi/Tsearch_V2_compound_words...
0
by: Daniel Thune, MCSE | last post by:
I am having a problem with formatting a SOAP Header in a .Net client. The client calls a Java Axis 1.1 based web service. In order to authenticate the caller, the web service call is intercepted by...
4
by: Jonathan [sbrodolo] | last post by:
Hi there, I am using a LOTUS/DOMINO Web Service in my ASP.Net application and I am having quite a lot of problems. I have managed to solve most of them but this one it really is giving me terrible...
16
by: pamelafluente | last post by:
I am still working with no success on that client/server problem. I need your help. I will submit simplified versions of my problem so we can see clearly what is going on. My model: A client...
0
by: myoungbl | last post by:
Note:I'm using VB.NET, .NET 2.0, to write a service application. So far I've only attempted to run it on the development machine. I'm have a couple of problems I can't quite figure out with a...
3
by: Russ | last post by:
I have a Web Service that was originally created with .NET VC 2003, and subsequently converted to the 2005 version. It works fine when built as a debug version, and run on the workstation it was...
5
by: Simon | last post by:
I have problem with namespaces. I have a program that consumes the web service and has for instance names space nsProgram. In this program I have defined several classes that I use for storing and...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.