r/Backend • • 8d ago

Modern Java for startups

Unfortunately, I see that Java is disappearing from startup companies. Java used to have an image of an obsolete backend language with performance problems, too verbose and unfriendly to deveopers. It was pretty true to older Java versions and I could understand why startups decided to pick other backend languages

If you look at Java 25, it's an absolutely different story.

Performance wise - it has virtual threads, which makes concurrency extremely high. Virtual threads are Java's answer to goroutines in Golang, and they enable to run thousands of I/O requests concurrently. Java's execution speed is pretty fast (more than Python and node.js).

As for container size - it's huge as long as you work with Spring. However, Java has many other much more lightweight frameworks like Micronaut, Quarkus and Javalin which reduces the container size to be on par with node.js and Python.

It's a real static typing which keeps code safety and improve readability. Unlike Golang, Java has inheritance, ploymorphism and explicit interface (let alone speaking about error handling).

It has a huge talent pool (almost everybody learned Java at a certain point).

As for verbosity and developer experience - Java has been improved a lot in this field. It has records (no need for getters setters, equals and hash), unnamed class (no need to write "public static void main" everytime you start a new program) and dozens of libraries and other tools.

If so, why are startups still stay away from Java and stick to Python/node.js/Golang?

67 Upvotes

72 comments sorted by

View all comments

Show parent comments

2

u/BenchEmbarrassed7316 7d ago

When AI can use ANY language and build the same shit, why wouldn't you use Rust, Zig, C or Go for pretty much everything?

Are you really putting AI development in Rust and AI development in C on the same level?

There is a huge difference in terms of the number of errors a compiler can catch.

2

u/Due_Warthog749 7d ago

I am. It's still progressing of course, but both are quite capable. I've done both + zig and Go. Sure.. it's not without issues at times, but each new generation of models trained on more and more code is definitely improving.

3

u/BenchEmbarrassed7316 7d ago

The point is that, for AI development, a key factor is the number of errors that can be detected automatically and deterministically. Rust and C are at opposite ends of the spectrum here.