Loading ...
Sorry, an error occurred while loading the content.

Re: [soaplite] Calling a .NET service

Expand Messages
  • Todd Tyree
    Bruno, Have you had any luck with this yet? If not, could you send me the +trace output, and I ll have a look to see if I can help? Cheers, Todd
    Message 1 of 3 , Mar 8, 2004
    View Source
    • 0 Attachment
      Bruno,

      Have you had any luck with this yet? If not, could you send me the
      +trace output, and I'll have a look to see if I can help?

      Cheers,
      Todd

      Burno, Pierre wrote:

      > Hello,
      >
      >
      >
      > I am attempting to connect to a .NET service and pass simple parameters,
      > strings and integers. But I am not having any success. Below is my
      > client code…Any suggestions?
      >
      >
      >
      >
      >
      > use SOAP::Lite +autodispatch =>+trace =>qw(all);
      >
      >
      >
      > my $soap = SOAP::Lite
      >
      > -> uri('…’)
      >
      > -> on_action( sub { join '/', '…’, $_[1] } )
      >
      > -> proxy('…')
      >
      > -> autotype(0)
      >
      > -> soapversion('1.1')
      >
      > -> envprefix('soap')
      >
      > -> encprefix('soap');
      >
      >
      >
      > my $method = SOAP::Data->name('Echo')
      >
      > ->attr({xmlns => '…'});
      >
      >
      >
      > my $response = SOAP::Data->name(value => 'mystring');
      >
      >
      >
      > print $soap->call($method => $response)->result;
      >
      >
      >
      >
      >
      >
      > *Yahoo! Groups Sponsor*
      > ADVERTISEMENT
      >
      >
      > ------------------------------------------------------------------------
      > *Yahoo! Groups Links*
      >
      > * To visit your group on the web, go to:
      > http://groups.yahoo.com/group/soaplite/
      >
      > * To unsubscribe from this group, send an email to:
      > soaplite-unsubscribe@yahoogroups.com
      > <mailto:soaplite-unsubscribe@yahoogroups.com?subject=Unsubscribe>
      >
      > * Your use of Yahoo! Groups is subject to the Yahoo! Terms of
      > Service <http://docs.yahoo.com/info/terms/>.
      >
      >
    • Todd Tyree
      Hi Pierre, There is nothing obvious. What should the return value be? teststring ? Hope you don t mind, but I m posting this back to the mailing list as
      Message 2 of 3 , Mar 9, 2004
      View Source
      • 0 Attachment
        Hi Pierre,

        There is nothing obvious. What should the return value be?
        'teststring'? Hope you don't mind, but I'm posting this back to the
        mailing list as well. I would like to keep it public in case anyone
        else has any sudden insights.

        Also, I see the version at the bottom of the mesage, but is that the
        version you are using? If not, could you attach a sanitized copy of the
        code you are using to generate the query?

        Here's a quick thought--have you tried setting an explicit type when
        building the soap data (try turning +autotyping on). Also, I assume
        you've gone through everything in the manpage regarding .NET
        interoperability, right?

        Also, what version of perl are you using?

        Best,
        Todd

        Burno, Pierre wrote:

        > Todd,
        >
        > No luck yet. Below is the trace output. Thank you for your assistance.
        >
        >
        >
        >
        > SOAP::Lite::new: ()
        > SOAP::Transport::HTTP::Client::new: ()
        > SOAP::Data::new: ()
        > SOAP::Data::new: ()
        > SOAP::Lite::call: ()
        > SOAP::Serializer::envelope: ()
        > SOAP::Serializer::envelope: SOAP::Data=HASH(0x1b76ab4)
        > SOAP::Data=HASH(0x1a3f4d4
        > )
        > SOAP::Data::new: ()
        > SOAP::Data::new: ()
        > SOAP::Data::new: ()
        > SOAP::Data::new: ()
        > SOAP::Transport::HTTP::Client::send_receive: HTTP::Request=HASH(0x1b849f8)
        > SOAP::Transport::HTTP::Client::send_receive: POST http://.../test.asmx
        > Accept: text/xml
        > Accept: multipart/*
        > Content-Length: 420
        > Content-Type: text/xml; charset=utf-8
        > SOAPAction: http://.../Service1/Echo
        >
        > <?xml version="1.0" encoding="UTF-8"?><soap:Envelope
        > xmlns:xsi="http://www.w3.or
        > g/1999/XMLSchema-instance" xmlns:xsd="http://www.w3.org/1999/XMLSchema"
        > soap:enc
        > odingStyle="http://schemas.xmlsoap.org/soap/encoding/"
        > xmlns:soap="http://schema
        > s.xmlsoap.org/soap/envelope/"><soap:Body><Echo
        > xmlns="http://.../Service1/"><value>teststring</value></Echo></soap:B
        > ody></soap:Envelope>
        > SOAP::Transport::HTTP::Client::send_receive: HTTP::Response=HASH(0x1d73f30)
        > SOAP::Transport::HTTP::Client::send_receive: HTTP/1.1 200 OK
        > Cache-Control: private, max-age=0
        > Date: Mon, 08 Mar 2004 21:04:18 GMT
        > Content-Type: text/xml; charset=utf-8
        > Client-Date: Mon, 08 Mar 2004 21:04:46 GMT
        > Client-Peer: 216.65.214.219:80
        > Client-Response-Num: 1
        > Client-Transfer-Encoding: chunked
        > MicrosoftOfficeWebServer: 5.0_Pub
        > X-AspNet-Version: 1.1.4322
        > X-Powered-By: ASP.NET
        >
        > <?xml version="1.0" encoding="utf-8"?><soap:Envelope
        > xmlns:soap="http://schemas.
        > xmlsoap.org/soap/envelope/"
        > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance
        > " xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><EchoResponse
        > xmlns="h
        > ttp://.../Service1" /></soap:Body></soap:Envelope>
        > SOAP::Deserializer::deserialize: ()
        > SOAP::Parser::decode: ()
        > SOAP::SOM::new: ()
        > SOAP::Lite::DESTROY: ()
        > SOAP::Serializer::DESTROY: ()
        > SOAP::Data::DESTROY: ()
        > SOAP::Data::DESTROY: ()
        > SOAP::Data::DESTROY: ()
        > SOAP::Data::DESTROY: ()
        > SOAP::Data::DESTROY: ()
        > SOAP::Data::DESTROY: ()
        > SOAP::Deserializer::DESTROY: ()
        > SOAP::Transport::DESTROY: ()
        > SOAP::Transport::HTTP::Client::DESTROY: ()
        > SOAP::SOM::DESTROY: ()
        > SOAP::Transport::DESTROY: ()
        > SOAP::Serializer::DESTROY: ()
        > SOAP::Deserializer::DESTROY: ()
        > SOAP::Parser::DESTROY: ()
        > SOAP::Lite::DESTROY: ()
        >
        >
        > -----Original Message-----
        > From: Todd Tyree [mailto:todd@...]
        > Sent: Monday, March 08, 2004 3:47 PM
        > To: soaplite@yahoogroups.com
        > Cc: Burno, Pierre
        > Subject: Re: [soaplite] Calling a .NET service
        >
        > Bruno,
        >
        > Have you had any luck with this yet? If not, could you send me the
        > +trace output, and I'll have a look to see if I can help?
        >
        > Cheers,
        > Todd
        >
        > Burno, Pierre wrote:
        >
        >
        >>Hello,
        >>
        >>
        >>
        >>I am attempting to connect to a .NET service and pass simple parameters,
        >>strings and integers. But I am not having any success. Below is my
        >>client code...Any suggestions?
        >>
        >>
        >>
        >>
        >>
        >>use SOAP::Lite +autodispatch =>+trace =>qw(all);
        >>
        >>
        >>
        >>my $soap = SOAP::Lite
        >>
        >> -> uri('...')
        >>
        >> -> on_action( sub { join '/', '...', $_[1] } )
        >>
        >> -> proxy('...')
        >>
        >> -> autotype(0)
        >>
        >> -> soapversion('1.1')
        >>
        >> -> envprefix('soap')
        >>
        >> -> encprefix('soap');
        >>
        >>
        >>
        >>my $method = SOAP::Data->name('Echo')
        >>
        >> ->attr({xmlns => '...'});
        >>
        >>
        >>
        >>my $response = SOAP::Data->name(value => 'mystring');
        >>
        >>
        >>
        >>print $soap->call($method => $response)->result;
        >>
        >>
        >>
        >>
        >>
        >>
        >>*Yahoo! Groups Sponsor*
        >>ADVERTISEMENT
        >>
        >>
        >>------------------------------------------------------------------------
        >>*Yahoo! Groups Links*
        >>
        >> * To visit your group on the web, go to:
        >> http://groups.yahoo.com/group/soaplite/
        >>
        >> * To unsubscribe from this group, send an email to:
        >> soaplite-unsubscribe@yahoogroups.com
        >> <mailto:soaplite-unsubscribe@yahoogroups.com?subject=Unsubscribe>
        >>
        >> * Your use of Yahoo! Groups is subject to the Yahoo! Terms of
        >> Service <http://docs.yahoo.com/info/terms/>.
        >>
        >>
      Your message has been successfully submitted and would be delivered to recipients shortly.