Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re^3: How to create soap server script?

by sundialsvc4 (Monsignor)
on Oct 06, 2010 at 03:07 UTC ( #863714=note: print w/ replies, xml ) Need Help??


in reply to Re^2: How to create soap server script?
in thread How to create soap server script?

I’m afraid that I don’t understand your point/question.   Could you please rephrase it?   Elaborate a little?


Comment on Re^3: How to create soap server script?
Re^4: How to create soap server script?
by Boring (Novice) on Oct 06, 2010 at 05:22 UTC
    Hi sundialsvc4,

    server script -> hibye.cgi

    #!perl -w use SOAP::Transport::HTTP; SOAP::Transport::HTTP::CGI -> dispatch_to('Demo') -> handle; package Demo; sub hi { return "hello, world"; } sub bye { return "goodbye, cruel world"; } sub languages { return ("Perl", "C", "sh"); }

    The above sample code is from "http://guide.soaplite.com/#autodispatching"

    Correct me if I'm wrong:

    If client call server->hibye.cgi->sub hi

    hibye.cgi will go to package Demo->sub hi and return "hello, world"

    So, my questions are:

    If there is a wsdl, can I still use the above code?

    and

    the above sample code, the dispatch_to is "hard coded", can I do dynamic?

    Please advise. Thanks.

      Please understand that I am not an authority on this one, having not done SOAP in quite some time now, but ...

      The WSDL is (afaik...) an external description of what your service has to offer.   Your implementation must conform to it, but your server-side code is not influenced by it.   (It would be very nice if it did, and perhaps there is another package that does.)

      As guide.soap.com indicates, access can either be dynamic or static.   “Dynamic” means that you specify a directory-name, and Perl looks for a module within that directory.   If it finds one, it loads it and uses it.   (See: "Different modules on one server.")   A hybrid approach can also be used.   But these implementation details are not apparent to the client.

        Hi sundialsvc4,

        Thanks for your advice and information.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://863714]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (14)
As of 2014-08-21 14:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (136 votes), past polls