Unless you are implementing hardcore algorithms that work on data in-memory, you are losing time
by writing code in C++. Most of the challenges with writing a web service revolve around accessing data in efficient, predictable patterns that are amenable to caching and even distribution with respect to queries per second. For example, a system to dump a user's post to a database wouldn't benefit from C++; if you are hitting the limits of the language's speed, then you will almost certainly end up with a monotonically growing backlog of DB writes. On the other hand, a search engine would need to do many string operations very quickly on in-memory data structures. That is a service that you would probably write in C++ and connect to via RPC.
In my experience, it's generally much faster to write and debug large java codebases than it is to write and debug large C++ ones, hence the comment about los... (more)