inzoik has asked for the wisdom of the Perl Monks concerning the following question:
With SOAP::Trace enabled the soap body for the POE code above wasuse POE; use POE::Component::Server::SOAP; POE::Component::Server::SOAP->new( 'ALIAS' => 'MySOAP', 'ADDRESS' => 'localhost', 'PORT' => 32080, ); POE::Session->create( 'inline_states' => { '_start' => \&setup_service, '_stop' => \&shutdown_service, 'hi' => \&hi, }, ); $poe_kernel->run; exit 0; sub setup_service { my $kernel = $_[KERNEL]; $kernel->alias_set( 'Demo' ); $kernel->post( 'MySOAP', 'ADDMETHOD', 'Demo', 'hi' ); } sub shutdown_service { $_[KERNEL]->post( 'MySOAP', 'DELMETHOD', 'Demo', 'hi'); } sub hi { my $response = $_[ARG0]; my $params = $response->soapbody; $response->content( "Hello" ); $_[KERNEL]->post( 'MySOAP', 'DONE', $response ); } 1;
Whereas the Apache::SOAP code below<namesp1:hiResponse xmlns:namesp1="http://127.0.0.1:32080/"> <s-gensym3 xsi:type="xsd:string">Hello</s-gensym3> </namesp1:hiResponse>
is generating#!/usr/bin/perl use SOAP::Transport::HTTP; SOAP::Transport::HTTP::CGI ->dispatch_to('Demo') ->handle; package Demo; sub hi { return 'Hello'; } 1;
The above difference is preventing a .Net client from reading the response. Any suggestions or pointers would be highly appreciated.<hiResponse xmlns="http://127.0.0.1/Demo"> <s-gensym3 xsi:type="xsd:string">Hello</s-gensym3> </hiResponse>
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Adding namespace in Method Response
by ikegami (Patriarch) on Aug 12, 2010 at 20:53 UTC | |
by inzoik (Novice) on Aug 12, 2010 at 21:08 UTC | |
by ikegami (Patriarch) on Aug 12, 2010 at 21:40 UTC | |
|
Re: Adding namespace in Method Response
by Anonymous Monk on Aug 12, 2010 at 21:08 UTC | |
by inzoik (Novice) on Aug 12, 2010 at 23:14 UTC |