I have a C++ program, and I want to make it as a web service listening to http request. I am a newbie to web development. Could some one give me a guild to tools/library/APIs that can help me build it. I know Java program usually restlet. What is the equivalent of restlet for C++?
Asked
Active
Viewed 1,886 times
2
-
gSOAP is the first result for "c++ web services" and sounds like what you want. http://www.cs.fsu.edu/~engelen/soap.html – nickrak Aug 17 '13 at 04:51
-
SOAP is a more complicate protocol then REST used in restlet. REST means encoding information as simple strings with more complex information passed as request body. A C++ REST library was recommended [here](http://stackoverflow.com/questions/1961238/can-anyone-recommend-a-good-c-c-restful-framework) – cpp Aug 17 '13 at 07:09
-
I am looking at CPPCMS, CPPSERV, and A Stream Socket API for C++:http://www.pcs.cnu.edu/~dgame/sockets/socketsC++/sockets.html, can anyone tell me which is better, and the comparison between them – realmq Aug 20 '13 at 02:33
-
What was the reason for not selecting an answer? – László Papp May 30 '14 at 01:50
-
Asynchronous C++11 RESTful framework: https://github.com/Corvusoft/restbed – Ben Crowhurst Jun 19 '15 at 15:55
4 Answers
3

László Papp
- 51,870
- 39
- 111
- 135
-
-
I am looking at CppCMS, but couldn't find an example that illustrates how to use for my purpose. – realmq Aug 19 '13 at 17:26
-
plus, I also found this: CPPSERV, comparing to CppCMS, which is better ? – realmq Aug 19 '13 at 20:29
-
@emilywuq: it is primarily opinion based, but I would use CppCMS. Any reason why you have not selected an accepted answer? – László Papp Oct 05 '13 at 03:25
1
The old, classic way to make existing C/C++ executable available on the web is through CGI. A web server that supports CGI can be configured to interpret an URL as a reference to a CGI script that can be directly your executable or a simple wrapper around it. The web for fields are provided as standard input and the program's output becomes the server response.

Audrius Meškauskas
- 20,936
- 12
- 75
- 93
0
I am working on something similar in Python and I am also newcomer on this field. You might be interested in sockets
, see: http://goo.gl/r6X4u, http://goo.gl/enffd

gen
- 9,528
- 14
- 35
- 64