Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to deploy a gSOAP Web Service in Ubuntu?

I have a doubt concerning the deployment of a Web Service in Ubuntu. It was implemented using gSOAP and it should be deployed, e.g. be accessible from websites (which are developed in e.g. ASP .NET).

I got confused with the whole CGI, Ubuntu, Apache topics. Until now I was able to implement a Web Service in ASP .NET and deploy it on Microsoft ISS. Other than that I can also access a gSOAP Web Service described in a WSDL, using ASP .NET

What are the steps to deploy my own Web Service? I have some more specific questions:

  1. Do I have to compile the WS as CGI?
  2. Do I have to install Apache in Ubuntu or the service is already enabled?
  3. In which particuar directory do I have to place the generated code from the WS compilation ("CGI" I guess)?

I am quite a newbie with regard to gSOAP and the whole "Web Service world", especially in Ubuntu...

Thank you very much in advance!

like image 340
Julen Avatar asked Feb 24 '23 17:02

Julen


1 Answers

Do I have to compile the WS as CGI? Do I have to install Apache in Ubuntu or the service is already enabled?

No, gSoap doesn't need Apache, gSoap implements a standalone server. The gSoap documentation recommends not to use CGI because it's stateless and slow. Instead you should use the standalone server or the gSoap Apache modules included in the package. I use gSoap as standalone service with Debian. Therefore I did following (summarized):

  1. Install gSoap: apt-get install gSoap
  2. Manually created the header file (e.g. header.h)
  3. Create the client and server files with soapcpp2 -I /usr/include/gsoap header.h
  4. Implemented the functions declared in header.h

Good luck

like image 118
Christian Ammer Avatar answered Feb 27 '23 06:02

Christian Ammer