sumeetgrover has asked for the wisdom of the Perl Monks concerning the following question:

Hello Monks,

I have written Perl scripts and modules for several years professionally to interact with the OS and the filesystem.

What I 'have been asked to' implement now is a SOAP Web Service written in Perl that will do the following:
1. It will listen on (let's say) Port 2001 on a server.
2. It will accept a file upload from a remote server, and
3. It will save that file locally on the disk.

Now I have no experience in writing web services or web-oriented Perl. I would highly appreciate if anyone could guide me to links that I could read, and how I could get started. Of course, if the above - which I have simply been asked to implement - is not possible, I would appreciate if you could tell me an overall design (e.g. APACHE/Perl-script) that I could use to implement this.

If you need me to clarify anything, let me know.

  • Comment on Perl SOAP Web Service to Accept File Uploads

Replies are listed 'Best First'.
Re: Perl SOAP Web Service to Accept File Uploads
by thanos1983 (Parson) on Mar 27, 2019 at 11:08 UTC
      Thanks for the links. They have all the information I need for now.

      Hi thanos1983,

      One more question for you: By looking at "Quick Start with SOAP" web page link you sent me, it would appear that the SOAP Server script (CGI script in this instance) would need to run on a web server? (e.g. on Apache)

      So that the Client script could call, for example, http://localhost/SOAPServer.cgi? My question is: Does running a SOAP Service require an HTTP Web Server to run as well? (Please excuse my ignorance.)

        sumeetgrover:

        You'll have to have *something* that acts as a webserver, but it doesn't have to be a full-featured web server like Apache or Nginx. You could use Plack or HTTP::Server::Simple or you could even roll your own. It just has to serve up a network connection and be able to direct the incoming request to your SOAP handler subroutine.

        ...roboticus

        When your only tool is a hammer, all problems look like your thumb.

        Hello again sumeetgrover,

        Fellow Monk roboticus answered your question, but just to add something minor that maybe you find it useful. I used to work with SOAP/REST requests to my DB (MySQL) and for testing purposes I always had a webserver running for multiple reasons. For me handling the DB through the GUI (phpMyAdmin) made my life much easier for testing and DB modifications. Secondary reason was to test SOAP/REST and to be honest usually I was combining it with GUI again for the same reasons.

        The tool that I found really easy to install and configure to include all these together was LAMP (LinuxOS) and WAMP (WindowsOS).

        Hope this helps you with your task as it did for me. :)

        P.S.: (Please excuse my ignorance.) You are just starting with this area, never stop asking questions! You will never know the answer to a question until you will understand it and experiment (hands on) information. Do not worry about the questions keep shooting and simultaneously start coding/experimenting. Soon you will be up and running. :)

        BR / Thanos

        Seeking for Perl wisdom...on the process of learning...not there...yet!