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

RE: [soaplite] Re: on_fault

Expand Messages
  • Ray Rizzuto
    Paul, I had a minor typo. In a timeout situation, in the fault handler: print $_[1] prints an empty string print defined $_[1] prints 1 print ref $_[1]
    Message 1 of 9 , Feb 14, 2001
    • 0 Attachment
      Paul,
       
      I had a minor typo.  In a timeout situation, in the fault handler:
       
      print $_[1] prints an empty string
      print defined $_[1]  prints 1
      print ref $_[1]  prints an empty string
       
      Since this is a transport error $_[1] is string, which is why ref $_[1] is empty.  Since the content of the returned message is empty in the case of a timeout, that explains why $_[1] is also an empty string.
       
      Ray
      -----Original Message-----
      From: Paul Kulchenko [mailto:paulclinger@...]
      Sent: Wednesday, February 14, 2001 4:16 PM
      To: soaplite@yahoogroups.com
      Subject: RE: [soaplite] Re: on_fault

      Hi, Ray!

      --- Ray Rizzuto <ray.rizzuto@...> wrote:
      > In your list of errors, I don't see the case I'm experiencing,
      > which is a timeout:
      >
      > 500 Can't connect to pc-rizzuto-p:9999 (Timeout)
      Agree. Fixed list:

      OK Transport + OK SOAP
      1. 200 OK + SOAP message (normal result)

      Error Transport + no SOAP
      2a. 500 Server Error + error message (not SOAP)
      2b. 400 Bad Method + error message (not SOAP)
      2c. 510 Not Extended + error message (not SOAP)
      2d. All other errors

      Error Transport + Fault SOAP
      3a. 500 Server Error + SOAP message (Fault result)
      3b. 400 Bad Method + SOAP message (Fault result)

      OK transport + Fault SOAP
      4. 200 OK + SOAP message (Fault result)

      > In that case, what should I get as the second parameter to the
      > fault
      > handler?  In the debugger, @_ has length 2, and print $_[1], but
      > print ref
      > $_[1] returns an empty string.  Is that because the content of the
      > response is empty?
      Exactly. ref $_[1] will return empty string even if $_[1] is not
      empty, but doesn't represent any referense and contains plain string,
      like 'abc'. That means that content of message either empty or not
      parsed.

      Best wishes, Paul.


      __________________________________________________
      Do You Yahoo!?
      Get personalized email addresses from Yahoo! Mail - only $35
      a year!  http://personal.mail.yahoo.com/


      To unsubscribe from this group, send an email to:
      soaplite-unsubscribe@yahoogroups.com


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