Hi,
Your problem is that the python server (Apache actually) is not
configured to accept chunked content. Either modify the apache
configuration to accept chunking or set the parameters at Axis2 client
to disable chunking.
See http://wso2.org/library/209

Ajith

On 10/25/07, 卢宾 <[EMAIL PROTECTED]> wrote:
>
>
> Hi, all,
>   I write a webservice using Python, implementing a simple 'Echo' method,
> and use a simple Axis2 client to access this webservice,  I do the following
> steps:
>   1. wsdl2java.bat -uri http://localhost/Echo.wsdl (generating two java
> files)
>   2. write a simple client to invoke the webservice
>  then , I got the following errors:
>   1. In Eclipse console:
>      "Exception in thread "main" org.apache.axis2.AxisFault: First Element
> must contain the local name, Envelope"
>   2. In apache error log:
>     [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1] chunked
> Transfer-Encoding forbidden: /EchoServer/.py
>     [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1] mod_python
> (pid=632, interpreter='localhost', phase='PythonHandler',
> handler='control'): Application error
>    [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1] ServerName:
> 'localhost'
>    [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1] DocumentRoot:
> 'D:/Program Files/Apache Group/Apache2/htdocs'
>    [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1] URI:
> '/EchoServer/.py'
>    [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1] Location: None
>    [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1] Directory:
> 'D:/Program Files/Apache Group/Apache2/htdocs/EchoServer/'
>    [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1] Filename:
> 'D:/Program Files/Apache
> Group/Apache2/htdocs/EchoServer/.py'
>    [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1] PathInfo: ''
>    [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1] Traceback (most
> recent call last):
>    [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1]   File
> "D:\\Python24\\Lib\\site-packages\\mod_python\\importer.py",
> line 1537, in  HandlerDispatch\n    default=default_handler, arg=req,
> silent= hlist.silent)
>   [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1]   File
> "D:\\Python24\\Lib\\site-packages\\mod_python\\importer.py",
> line 1229, in _process_target\n    result = _execute_target(config, req,
> object, arg)
>   [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1]   File
> "D:\\Python24\\Lib\\site-packages\\mod_python\\importer.py",
> line 1128, in _execute_target\n    result = object(arg)
>   [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1]   File "D:\\Program
> Files\\Apache
> Group\\Apache2\\htdocs\\EchoServer\\control.py", line 9, in
> handler\n    dispatch.AsHandler (modules=(EchoServer,),
> request=req,rpc=True)
>   [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1 ]   File
> "D:\\Python24\\Lib\\site-packages\\ZSI\\dispatch.py", line
> 189, in AsHandler\n    ps = ParsedSoap(request)
>   [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1]   File
> "D:\\Python24\\Lib\\site-packages\\ZSI\\parse.py", line 58,
> in __init__\n    str(e.__class__) + "): " + str(e), 0)
>   [Sat Oct 13 10:50:46 2007] [error] [client 127.0.0.1] ParseException:
> Can't parse document (_apache.SERVER_RETURN): 411
> My wsdl document is :
>
>
> <?xml version="1.0" encoding="UTF-8"?>
> <definitions
>   xmlns="http://schemas.xmlsoap.org/wsdl/ "
>   xmlns:soap=" http://schemas.xmlsoap.org/wsdl/soap/";
>   xmlns:soapenc="
> http://schemas.xmlsoap.org/soap/encoding/";
>   xmlns:http=" http://schemas.xmlsoap.org/wsdl/http/";
>   xmlns:xsd="http://www.w3.org/2001/XMLSchema";
>   xmlns:tns="http://localhost:80/Echo.wsdl "
>   targetNamespace=" http://localhost:80/Echo.wsdl"; >
>
>   <message name="EchoRequest">
>     <part name="in_str" type="xsd:string"/>
>   </message>
>   <message name="EchoResponse">
>     <part name="result" type="xsd:string"/>
>   </message>
>
>   <portType name="EchoServer">
>     <operation name="Echo">
>       <input message="tns:EchoRequest"/>
>       <output message="tns:EchoResponse"/>
>      </operation>
>   </portType>
>
>   <binding name="EchoServer" type="tns:EchoServer">
>     <soap:binding style="rpc"
>                   transport="
> http://schemas.xmlsoap.org/soap/http"/ >
>     <operation name="Echo">
>       <soap:operation soapAction="Echo"/>
>  <input>
>       <soap:body use="literal"/>
>  </input>
>  <output>
>    <soap:body use="literal"/>
>  </output>
>     </operation>
>   </binding>
>
>   <service name="EchoServer">
>     <port name="EchoServer" binding="tns:EchoServer">
>       <soap:address location="
> http://localhost:80/EchoServer/.py"/>
>     </port>
>   </service>
>
> </definitions>
> So what's the problem here? Thanks a lot!
>


-- 
Ajith Ranabahu

Reading, after a certain age, diverts the mind too much from its
creative pursuits. Any man who reads too much and uses his own brain
too little falls into lazy habits of thinking - Albert Einstein

Reply via email to