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

Re: [soaplite] Changing endpoint from a full wsdl file

Expand Messages
  • Weidong Wang
    Thanks, Paul and Randy. ... Paul, I tried it. I can put it anywhere in my code or library. When running, Perl will complain that SOAP::Lite::endpoint is
    Message 1 of 4 , Sep 28, 2002
    • 0 Attachment
      Thanks, Paul and Randy.

      > If WSDL includes the endpoint, you can overwrite the endpoint()
      > method to return the endpoint you want:
      >
      > sub SOAP::Lite::endpoint { return shift if @_ > 1; 'http://foo/' }
      >
      > That's the shortest solution I can come up with. Let me know if it
      > doesn't work for you.

      Paul, I tried it. I can put it anywhere in my code or library. When running, Perl will complain that SOAP::Lite::endpoint is redefined, but then it will use the new endpoint in this call.

      But it seems to me that having this sub will affect all WSDL calls, correct? In my app, I need to use multiple WSDL files for making different service calls. I suppose the existence of this sub will make all wrapper functions generated by service() call to use the new endpoint.

      It seesm to me if we can dynamically redefine this sub as needed and rerun service() call (much more overhead of course), we might be able to get around it?

      I will look into having the tModel kind of WSDL file.

      Thanks.

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