3 ms·
> No one would (should!) ever consider writing a webservice in C++, simply because it's unsafe to do so, it's much easier in other languages I wrote some years
by allan_s 11y ago
> No one would (should!) ever consider writing a webservice in C++, simply because it's unsafe to do so, it's much easier in other languages
I wrote some years ago https://github.com/allan-simon/cppcms-skeleton https://github.com/allan-simon/cppcms-skeleton
Which I used as a MVC C++ framework to create webapp, even a quite full featured wiki (multi-language, image uploading, markdown, history, conflict resolution with diff etc.) https://github.com/allan-simon/tatowiki https://github.com/allan-simon/tatowiki
which is used in production there http://wiki.tatoeba.org http://wiki.tatoeba.org for now several years too (without crash, of course one error 500 from times to times because there was some bug)
And it's not that hard to read and write I think https://github.com/allan-simon/tatowiki/blob/master/app/src/controllers/webs/Articles.cpp https://github.com/allan-simon/tatowiki/blob/master/app/src/...
Of course it was missing a lot of tooling (ORM, database migration etc.) but I don't think the language per se was the problem. And if counting the full stack of dependencies, my solution certainly had less line of C/C++ involved than your typical php application :)
For this, if i was to redo it in 2015, I would however consider Rust without any hesitation, especially as I think it has one major advantage compare to C/C++ regarding web services
=> the community wants to go that way and make library/framework to create webservices in Rust, first class citizen of the ecosystem