cours:service_oriented_computing_and_web_services:2017-2018:gsoap
Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédente | ||
cours:service_oriented_computing_and_web_services:2017-2018:gsoap [2018/04/12 05:08] – [gSOAP Toolkit Installation] tigli | cours:service_oriented_computing_and_web_services:2017-2018:gsoap [2018/04/12 13:35] (Version actuelle) – [How to publish a WSDL of a web service using gSOAP] tigli | ||
---|---|---|---|
Ligne 15: | Ligne 15: | ||
==== A Quick How-To ==== | ==== A Quick How-To ==== | ||
+ | ([[http:// | ||
== wsdl2h == | == wsdl2h == | ||
Ligne 34: | Ligne 35: | ||
== soapcpp2 : gSOAP Compiler == | == soapcpp2 : gSOAP Compiler == | ||
- | Now, we run the gSOAP compiler ' | + | Now, we run the gSOAP compiler ' |
- | {{ : | + | {{ : |
The gSOAP runtime library provides a transport layer with an HTTP stack on top of TCP/IP as well as secure SSL and DIME/MIME attachment support. | The gSOAP runtime library provides a transport layer with an HTTP stack on top of TCP/IP as well as secure SSL and DIME/MIME attachment support. | ||
- | To develop a service application, | + | To develop a service application, |
- | {{ : | + | {{ : |
+ | |||
+ | The ' | ||
- | The ' | ||
==== Tutorial : Getting Start with gSOAP ==== | ==== Tutorial : Getting Start with gSOAP ==== | ||
- | Write your first SOAP and REST Web Services | + | Here you can find a complete step by step tutorial to write yuor first SOAP and REST Web Services, from Hello World to the classical Calc : |
[[https:// | [[https:// | ||
Ligne 54: | Ligne 57: | ||
- | ==== Raspbian | + | ==== Publish the WSDL of your web service using gSOAP ==== |
+ | || | ||
+ | [[https:// | ||
+ | |||
+ | < | ||
+ | |||
+ | int http_get(struct soap *soap) | ||
+ | { | ||
+ | FILE *fd = NULL; | ||
+ | char *s = strchr(soap-> | ||
+ | if (!s || strcmp(s, "? | ||
+ | return SOAP_GET_METHOD; | ||
+ | fd = fopen(" | ||
+ | if (!fd) | ||
+ | return 404; // return HTTP not found error | ||
+ | | ||
+ | | ||
+ | for (;;) | ||
+ | { | ||
+ | size_t r = fread(soap-> | ||
+ | if (!r) | ||
+ | | ||
+ | if (soap_send_raw(soap, | ||
+ | | ||
+ | } | ||
+ | | ||
+ | | ||
+ | | ||
+ | } | ||
+ | |||
+ | </ | ||
+ | |||
+ | ==== Test the interoperability | ||
+ | |||
+ | After deploying the calc WS-SOAP, test its interoperability with a typical WCF client. | ||
+ | |||
+ | ==== Use gSOAP for monitoring ==== | ||
+ | |||
+ | Of course, this low level programming approach is not very useful to write classical services without any system challenge. | ||
- | Raspbian is a free operating system based on Debian optimized for the Raspberry Pi hardware. An operating system is the set of basic programs | + | On the other hand, as soon as you want to access to specific Operating System |
+ | To illustrate that choose your own prefered POSIX function and test it through a Web Service gSOAP. | ||
+ | If you don't have imagination try // getpid() //. | ||
cours/service_oriented_computing_and_web_services/2017-2018/gsoap.1523509730.txt.gz · Dernière modification : 2018/04/12 05:08 de tigli