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

Re: [soaplite] Help if you can

Expand Messages
  • Byrne Reese
    If the schema and WSDL URL s you provided below are the permanent locations of these documents than I believe the answer is simple: * your schema import is
    Message 1 of 6 , Aug 24, 2003
    • 0 Attachment
      If the schema and WSDL URL's you provided below are the permanent
      locations of these documents than I believe the answer is simple:

      * your schema import is failing because no schema exisits at the end of
      your WSDL's import statment.

      I tried loading:
      https://pirp.caiso.com/schemas/pirp/v1

      And nothing came up. I would also think that HTTPS is not the best
      protocol for storing the schema. :-/

      If the types never get defined, the deserializer will never work.

      > I've written soap clients before but never
      > anything this complicated. Here are the links
      >
      > PIRP: http://homer.meso.com/crap/PIRP_Schema_v1.xsd
      > WSDL: http://homer.meso.com/crap/OperationsService.wsdl
      >
      > Here is a link to what the XML request is supposed to look like
      > http://homer.meso.com/crap/getIntervalData_request.txt
      >
      > Here is my perl script
      >
      > http://homer.meso.com/crap/perl.txt
      >
      >
      > This is what I get
      > http://homer.meso.com/crap/getIntervalData_request.txt
      >
      >
      >>;faultstring
      > 'intervals': could not find deserializer for type
      > ArrayOfOperationInterval>;/faultstring
      >
      > for some reason that is wrong and for the life of me I canot figure
      > out why.
      >
      >
      > it almost seems like the wsdl file might be wrong.. but i think its
      > in the perl
      >
      >
      >
      >
      >
      >
      >
      >
      >
      > Yahoo! Groups Sponsor
      >
      >
      > ADVERTISEMENT
      >
      >
      >
      >
      >
      >
      >
      >
      >
      > To unsubscribe from this group, send an email to:
      > soaplite-unsubscribe@yahoogroups.com
      >
      >
      >
      >
      >
      > Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
      >
      >
      >
      >
      >


      ^byrne :/
    • jigsaw9876
      Hi, Can anyone give me a working example for sending and receiving attachments using SOAP::Lite, please? I have followed the example at
      Message 2 of 6 , Sep 4, 2003
      • 0 Attachment
        Hi,

        Can anyone give me a working example for sending and receiving
        attachments using SOAP::Lite, please? I have followed the example at
        http://majordojo.com/SOAP-MIME/samples and seem to be successful in
        sending attachments from the client. How does the server receive them?

        sub test {
        my $self = shift;
        my $envelope = pop;

        foreach my $part (@{$envelope->parts}) {
        print STDERR "test.cgi: attachment found! (".ref($$part).")\n";
        }

        my $num_parts = $envelope->parts(0);
        print STDERR $num_parts;
        ...
        }

        The above is part of my server code.
        I get a faultstring: Can't use an undefined value as an ARRAY reference
        and $num_parts is 1 while the envelope is of type SOAP::SOM
        I use Perl 5.8.0, SOAP::Lite 0.6.0 and MIME::Tools 5.411

        Am I missing soemthing obvious here?

        Regards,
        JS.
      • Byrne Reese
        Try this variant which in another example... foreach my $part (${$som- parts}) { print $part- stringify; } However, it LOOKS like $som- parts is undefined all
        Message 3 of 6 , Sep 4, 2003
        • 0 Attachment
          Try this variant which in another example...

          foreach my $part (${$som->parts}) {
          print $part->stringify;
          }

          However, it LOOKS like $som->parts is undefined all together, which would
          probably produce the same error. Have you verified that the server is
          receiving a MIME message? Meaning have you traced what the client is
          sending and receiving?

          > Hi,
          >
          > Can anyone give me a working example for sending and receiving
          > attachments using SOAP::Lite, please? I have followed the example at
          > http://majordojo.com/SOAP-MIME/samples and seem to be successful in
          > sending attachments from the client. How does the server receive them?
          >
          > sub test {
          > my $self = shift;
          > my $envelope = pop;
          >
          > foreach my $part (@{$envelope-
          > print STDERR "test.cgi: attachment found!
          > (".ref($$part).")\n";
          > }
          >
          > my $num_parts = $envelope-
          > print STDERR $num_parts;
          > ...
          > }
          >
          > The above is part of my server code.
          > I get a faultstring: Can't use an undefined value as an ARRAY reference
          > and $num_parts is 1 while the envelope is of type SOAP::SOM
          > I use Perl 5.8.0, SOAP::Lite 0.6.0 and MIME::Tools 5.411
          >
          > Am I missing soemthing obvious here?
          >
          > Regards,
          > JS.
          >
          >
          >
          >
          >
          >
          >
          >
          >
          > Yahoo! Groups Sponsor
          >
          >
          > ADVERTISEMENT
          >
          >
          >
          >
          >
          >
          >
          >
          >
          > To unsubscribe from this group, send an email to:
          > soaplite-unsubscribe@yahoogroups.com
          >
          >
          >
          >
          >
          > Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
          >
          >
          >
          >
          >


          ^byrne :/
        • jigsaw9876
          Hi, That didn t quite work either. I have tracing at the client side (I don t think I know/understand how to start tracing at server side though I have read
          Message 4 of 6 , Sep 5, 2003
          • 0 Attachment
            Hi,

            That didn't quite work either.
            I have tracing at the client side (I don't think I know/understand how
            to start tracing at server side though I have read various messages on
            that subject :-( ) And this is what it looks like:

            Content-Type: text/plain
            Content-Disposition: inline
            Content-Transfer-Encoding: quoted-printable
            MIME-Version: 1.0
            X-Mailer: MIME-tools 5.411 (Entity 5.404)

            First line
            Second line
            Last line
            SOAP::Transport::HTTP::Client::send_receive: POST
            http://localhost/cgi-bin/test.cgi HTTP/1.1
            Accept: text/xml
            Accept: multipart/*
            Content-Length: 927
            Content-Type: Multipart/Related; type="text/xml";
            start="<main_envelope>"; boundary="----------=_1062759837-19441-0";
            charset=utf-8
            SOAPAction: "Test#test"

            This is a multi-part message in MIME format...

            ------------=_1062759837-19441-0
            Content-Type: text/xml
            Content-Disposition: inline
            Content-Transfer-Encoding: 8bit
            Content-Location: /main_envelope
            Content-Id: <main_envelope>

            <?xml version="1.0" encoding="UTF-8"?><SOAP-ENV:Envelope
            xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
            xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
            xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
            xmlns:xsd="http://www.w3.org/1999/XMLSchema"
            SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
            <SOAP-ENV:Body><namesp1:test
            xmlns:namesp1="Test"/></SOAP-ENV:Body></SOAP-ENV:Envelope>
            ------------=_1062759837-19441-0
            Content-Type: text/plain
            Content-Disposition: inline
            Content-Transfer-Encoding: quoted-printable
            MIME-Version: 1.0
            X-Mailer: MIME-tools 5.411 (Entity 5.404)

            First line
            Second line
            Last line

            ------------=_1062759837-19441-0--

            SOAP::Transport::HTTP::Client::send_receive: HTTP/1.1 500 Internal
            Server Error
            Connection: close
            Date: Fri, 05 Sep 2003 11:03:57 GMT
            Server: Apache/1.3.26 (Unix) mod_jk/1.2.0
            Content-Length: 567
            Content-Type: text/xml; charset=utf-8
            Client-Date: Fri, 05 Sep 2003 11:03:57 GMT
            Client-Response-Num: 1
            SOAPServer: SOAP::Lite/Perl/0.60

            <?xml version="1.0" encoding="UTF-8"?><SOAP-ENV:Envelope
            xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
            xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
            xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
            xmlns:xsd="http://www.w3.org/1999/XMLSchema"
            SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
            <SOAP-ENV:Body><SOAP-ENV:Fault><faultcode>SOAP-ENV:Server</faultcode>
            <faultstring>Can't use an undefined value as a ARRAY reference at
            Test.pm line 16.
            </faultstring></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>


            Any ideas?

            TIA,
            JS



            --- In soaplite@yahoogroups.com, "Byrne Reese" <byrne@m...> wrote:
            > Try this variant which in another example...
            >
            > foreach my $part (${$som->parts}) {
            > print $part->stringify;
            > }
            >
            > However, it LOOKS like $som->parts is undefined all together, which
            would
            > probably produce the same error. Have you verified that the server is
            > receiving a MIME message? Meaning have you traced what the client is
            > sending and receiving?
            >
          • jigsaw9876
            Hi, Can anyone provide me with a working piece of code sending and receiving attachments using soaplite, please? I am quite new to perl/soaplite, so could be
            Message 5 of 6 , Sep 8, 2003
            • 0 Attachment
              Hi,

              Can anyone provide me with a working piece of code sending and receiving
              attachments using soaplite, please? I am quite new to perl/soaplite, so could be
              making some obvious mistakes. Would appreciate any help. Should I resort to Axis?

              Thanks.
              JS
            Your message has been successfully submitted and would be delivered to recipients shortly.