Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Issue with SOAP::Lite making two POSTs

by perlden (Initiate)
on Feb 12, 2009 at 12:24 UTC ( [id://743285]=perlquestion: print w/replies, xml ) Need Help??

perlden has asked for the wisdom of the Perl Monks concerning the following question:

Hello I'm having an issue with SOAP::Lite that I can't get the hang of. I'm on a Debian server and the server I'm posting to is a Microsoft-IIS/6.0 with ASP.net and I get everything to work and all but I get a strange behavior that I can't find any info on. The POST message gets sent and the server responds with the correct data. But then another POST call is made with the same SOAPAction but with "/code" on the end. I haven't been able to find anything on this anywhere and I haven't been able what it is that initiate the second call, if it's SOAP::lite or the windows server. Here's the debuginfo:
SOAP::Transport::new: () SOAP::Serializer::new: () SOAP::Deserializer::new: () SOAP::Parser::new: () SOAP::Lite::new: () SOAP::Lite::new: () SOAP::Data::new: () SOAP::Transport::HTTP::Client::new: () SOAP::Data::new: () SOAP::Data::new: () SOAP::Lite::call: () SOAP::Serializer::envelope: () SOAP::Data::new: () SOAP::Serializer::envelope: SOAP::Data=HASH(0xbe3890) SOAP::Data=HASH( +0xbe37d0) SOAP::Data::new: () SOAP::Data::new: () SOAP::Data::new: () SOAP::Data::new: () SOAP::Data::new: () SOAP::Transport::HTTP::Client::send_receive: HTTP::Request=HASH(0xbe34 +a0) SOAP::Transport::HTTP::Client::send_receive: POST xxxx HTTP/1.1 Accept: text/xml Accept: multipart/* Accept: application/soap Content-Length: 712 Content-Type: text/xml SOAPAction: xxxxxx POST XML SOAP::Transport::HTTP::Client::send_receive: HTTP::Response=HASH(0x9f7 +a60) SOAP::Transport::HTTP::Client::send_receive: HTTP/1.1 200 OK Connection: close Date: Thu, 12 Feb 2009 11:44:07 GMT Server: Microsoft-IIS/6.0 Content-Type: text/xml; charset=utf-8 Client-Date: Thu, 12 Feb 2009 11:44:07 GMT Client-Peer: 192.168.34.148:80 Client-Response-Num: 1 Set-Cookie: JSESSIONID=xxxx path=/xxxx X-Powered-By: ASP.NET X-Powered-By: ServletExec/5.0p06, Servlet/2.4, JSP/2.0 XML response comes here SOAP::Lite::call: () SOAP::Serializer::envelope: () SOAP::Serializer::envelope: code SOAP::Data::new: () SOAP::Data::DESTROY: () SOAP::Data::DESTROY: () SOAP::Data::DESTROY: () SOAP::Data::DESTROY: () SOAP::Data::DESTROY: () SOAP::Data::new: () SOAP::Data::new: () SOAP::Data::new: () SOAP::Transport::HTTP::Client::send_receive: HTTP::Request=HASH(0xbe34 +a0) SOAP::Transport::HTTP::Client::send_receive: POST xxxx HTTP/1.1 Accept: text/xml Accept: multipart/* Accept: application/soap User-Agent: SOAP::Lite/Perl/0.071004 Content-Length: 466 Content-Type: text/xml SOAPAction: xxxx/code //why does this happen? I'm not doing this as + far as I know hehe POST XML SOAP::Transport::HTTP::Client::send_receive: HTTP::Response=HASH(0xe9c +b50) SOAP::Transport::HTTP::Client::send_receive: HTTP/1.1 500 Internal ser +ver error Connection: close Date: Thu, 12 Feb 2009 11:44:07 GMT Server: Microsoft-IIS/6.0 Content-Type: text/xml; charset=utf-8 Client-Date: Thu, 12 Feb 2009 11:44:07 GMT Client-Peer: 192.168.34.148:80 Client-Response-Num: 1 Set-Cookie: JSESSIONID=xxxx path=/xxxx X-Powered-By: ASP.NET X-Powered-By: ServletExec/5.0p06, Servlet/2.4, JSP/2.0 <?xml version="1.0" encoding="UTF-8"?> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envel +ope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http:// +www.w3.org/2001/XMLSchema-instance"> <soapenv:Body> <soapenv:Fault> <faultcode>soapenv:Server.userException</faultcode> <faultstring>xxxx</faultstring> <detail/> </soapenv:Fault> </soapenv:Body> </soapenv:Envelope> SOAP::Data::DESTROY: () SOAP::Data::DESTROY: () SOAP::Data::DESTROY: () SOAP::Data::DESTROY: () SOAP::Data::DESTROY: () SOAP::Data::DESTROY: () SOAP::Transport::HTTP::Client::DESTROY: () SOAP::Data::DESTROY: () SOAP::Deserializer::DESTROY: () SOAP::Transport::DESTROY: () SOAP::Serializer::DESTROY: () SOAP::Transport::DESTROY: () SOAP::Serializer::DESTROY: () SOAP::Deserializer::DESTROY: () SOAP::Parser::DESTROY: () SOAP::Lite::DESTROY: () SOAP::Data::DESTROY: () SOAP::Lite::DESTROY: ()
Anyone got any idea why the second call is made? I don't want the second call but can't figure out how to stop it.

Replies are listed 'Best First'.
Re: Issue with SOAP::Lite making two POSTs
by Corion (Patriarch) on Feb 12, 2009 at 12:26 UTC

    Maybe your code is sending the second POST request?

      This is the code that makes the request:
      use SOAP::Lite (+trace => 'all', maptype => {}, encoding => 'iso-8859- +1', readable => 1 ); my $soap = SOAP::Lite $soap->outputxml(1); $soap->proxy('http://xxxx', timeout => '60' ); $soap->uri('urn:xxxx'); $soap->on_action( sub { join '/', 'xxxx', $_[1] } ); //@params gets filled with the data tags my $method = SOAP::Data->name( 'xxxx' ); my $result = $soap->call($method => @params)
      Sorry but I have to strip out some things. Anyway, there isn't another call being made in the code. So it seems that either SOAP::lite takes an initiative to make another call or the server tells it to, I'm not sure.
        Upgrade, latest is SOAP::Lite 0.710.08

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://743285]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (4)
As of 2024-04-24 20:08 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found