|
|
|
|
|
by imtringued
2393 days ago
|
|
I have some very simple lua processes that consume 2MB. They basically do nothing but listen to a websocket and run some shell comands. Lets say I have 3 of those. With the JVM I would have blown away more than half a gigabyte. Even with micronaut you're looking at 100MB per process. This just isn't sustainable. I personally think the JVM is a piece of crap because of this. There is GraalVM but compilation takes a relatively long time even compared to a C++ project and as soon as you use features that it doesn't support it will fail to work which means you are stuck with Java because you don't want to risk using a language that doesn't officially support GraalVM (groovy kotlin etc). |
|
You may be right that Java doesn't scale down well, but that's not normally the sort of work it's intended for. (Let's ignore the applets mistake.) It's a terrible solution for scripting, yes, but for heavyweight server roles I'd be surprised to see it significantly outperformed by .Net, and there's really no way Lua or Python would be able to compete.
OpenJDK has a very impressive (and heavyweight) JIT, for instance, and very impressive GCs of almost no use for short-lived applications.
With all that said, it'd be great if OpenJDK's new developments mature to the point that Java can become practical for 'lightweight work'.