3 ms·
Java isn’t dying overall, but it may not be the best choice for backend web apps. First, it’s the incumbent in most enterprise settings and will be around for m
by reilly3000 4y ago
Java isn’t dying overall, but it may not be the best choice for backend web apps. First, it’s the incumbent in most enterprise settings and will be around for many years to come, requiring maintenance and updates. Also Android has brought millions of developers into its ecosystem.
The thing is that the underlying infrastructure of web backends has fundamentally shifted towards horizontal scaling away from the days of big metal. As opposed to a small number of fixed servers that serve a predictable amount of requests, modern backends are autoscaling or serverless and handling massive amounts of requests at a moment’s notice. Concurrency doesn’t matter as much when compute resources scale to meet demand. What does matter is startup time, and that is where Java is weakest.
Go is orders of magnitude faster than Java for responding to the first request. It also comes along with strong concurrency primitives and solid web frameworks. So you can run it with very few instances by default and quickly scale to meet demand. It also requires less effort to manage memory and GC.
Java has a vast ecosystem which is both an asset and liability. You can be sure that whatever you’re attempting to do with Java has already been done at least 5 different ways. That can make it difficult to decide on what the best approach to use, which library to select, etc.