Live data from Hacker News

Java Is Underhyped

jackson.sh

631–640 of 808 posts

Re: Java Is Underhyped

#631
post #584
post #568

Earlier quoted context omitted.

Having thousand NPC objects around is no problem at all. The rendering part is the only thing critical/numerous enough that you may have to optimize to such a low level.

Not sure what you cover by "NPC objects" but they easily can participate in physics and AI as well (or at least basic scripted behavior). Also significant game state is not only represented by renderable content.

Well, if it’s physics as well, then yeah having a separate NPC objects may not be the best idea (though if the physics engine awaits some primitives, like for each “object” 3 coordinates before simulation, and then sets the corresponding position on each NPC, it may be fast enough). But Valhalla really is coming, and until many many games have more than enough performance packed in the JVM already.

Re: Java Is Underhyped

#632
post #615

Earlier quoted context omitted.

Well Java is arguably one of the most IDE-reliant mainstream languages. It's completely unusable and unergonomic without the myriad of constant code generation and fixing as you write. Treating the IDE like a separate problem is not realistic with java. With e.g. Rust, I can use vim, vscode, whatever floats your boat. > no idea why you'd have to configure "getting the actual logs"? Some genius java logging library, I…

> Well Java is arguably one of the most IDE-reliant mainstream languages. It's completely unusable and unergonomic without the myriad of constant code generation and fixing as you write. True, but with IntelliJ 99% of what you wrote is auto-configured. Eclipse needs a bit of hand-holding, but almost everything you described is due to project configuration. > Some genius java logging library, I can only guess. That's…

> with IntelliJ 99% of what you described is auto-configured

It is not, that's what I'm saying. And I don't understand why, if IntelliJ is the de-facto IDE. I'm sure that a fresh project is a one-click import, but an average project that isn't fresh anymore, always have similar IDE-setup-magic problems. At least in my experience over the years.

Re: Java Is Underhyped

#633

Earlier quoted context omitted.

Why would any reasonable person limit their choices based on a tool? Rust or Blast - whatever I really don’t care what language I’m using if it it doing the job. I use Java, Java Script, Go, Python, Scala when appropriate.

You just asked "Why would any reasonable person care what they spent half of their waking hours of their life doing?" The fact that you don't care does not make everyone other than you not a reasonable person. Frankly I don't see how any reasonable person could fail to develop some preferences, but I bet you would not like it if I called you unreasonable, or perhaps just unsophisticated.

Because preferences are based on emotions are not rational.

I’m talking about picking a tool that does the job according to the requirements (speed, memory, debuggability), not based on what some YouTuber said.

We are engineers and paid for results. It help with carrier to embrace it.

Re: Java Is Underhyped

#634
post #529

Earlier quoted context omitted.

Providing records was never about providing properties, but yes I agree properties would be a great addition. > They throw out Java EE instead of improving it Giving EE to the Eclipse foundation and transitioning it to Jakarta EE is about improving it. It allows the Eclipse foundation to move faster without having to go through the JDK standardization process.

The first thing they did is performed source-incompatible change of package names. That's hardly improving in my book, more like sabotaging. I understand that's because of trademarks, but that's another issue: why didn't Oracle provide all the necessary legal protections at least for package names.

A cynic might suggest that Oracle deliberately sabotaged Java EE because competitors like IBM and RedHat had beaten it in the marketplace and were making all the money off it.

Re: Java Is Underhyped

#635
post #549
post #343

Earlier quoted context omitted.

> - you can integrate code from hundreds of developers fairly safely (knowing that no one has changed the default behaviour fo builtins and different dependencies won't clash). It's exceedingly rare for this to be untrue of Python — it's technically possible to hack builtins but there's intense community pressure against doing that. > - the syntax, although not the most succinct is fairly easily readable and maintain…

> This is sort of true but it misses the aspect which makes Java hard to maintain The boilerplate syntax you talk about comes from like java 1.4. Modern Java is quite expressive with streams and lambdas. If one does employ the Java Beans convention than yeah, he/she has to autogenerate a few getters setters, but those don’t occlude the actual logic. And frankly, empirically, Java is anything but hard to maintain. You…

> The boilerplate syntax you talk about comes from like java 1.4.

I was thinking about things I've recently seen in new Java 15 code, so no. There are lots of old APIs in the Java language and popular libraries, and while things like streams are quite powerful, they're far from universal. I still see developers cranking out code which has to do what is built-in in other languages.

As a simple example, not having multiple return means that you end up with worse APIs in some cases or small classes which exist to wrap a couple of things — not necessarily terrible but it means that you've just taken on maintenance work for something which would be trivial in other languages. That extra code isn't exactly a huge lift but when you add things like that up regularly it's not hard to understand why all of the good Java developers I know are keenly following things like Kotlin which give more expressiveness without giving up all of their familiar tools.

Re: Java Is Underhyped

#637
post #407

Earlier quoted context omitted.

> I too think that IDEA is an excellent IDE, but why should Java take the credit for it. If anything, the more it needs an excellent IDE in order to feel pleasant, the worse it says about the language itself. It actually does, the language itself makes those features possible. The reason javascript does not have as good IDE is that language itself stands in a way.

It's a bit of a "stop hitting yourself" situation. Java features make awesome tooling possible, but awesome tooling is necessary due to some really bad features of Java. So I don't care if a different language has worse tooling when it also does not have the problems that Java has that the tooling solves.

The result of that tooling is better. It is easier to read, navigate, refactor and write then supposedly superior language without tooling.

The large the project, the bigger the gap gets.

Re: Java Is Underhyped

#638

For my use cases, Java has all the wrong compromises: - not high level enough to compete with Python/Ruby/JS/PHP, etc - not low level enough to compete with Rust/D/Nim/Zig - not specialized enough to compete with Erlang/R/Go/Julia - not opinionated enough to compete with Lisp/Haskell So why use Java ? It's good, it's fast, it's productive, it's well supported, battle tested and documented for decades with a huge pool…

Java is very high level - it runs on a VM and manages memory for you.

I think the opinion you're trying to convey is "not untyped enough".

Re: Java Is Underhyped

#639
Java is rock stable and "complete". Not just the language itself. Build tools, JVM, profiling, dependency management. Everything is at least decent, most language problems were solved years ago. I have used many languages and nothing comes close to Java in the balance of speed, flexibility, ecosystem, and polish. If you're not sure which language will be best for a project, Java is perfect.

I work on a codebase with hundreds of thousands of lines that haven't been touched in 15 years. We're on Java 11 with plans to update to 17 later this year. Our 8->11 upgrade took me 3 days on a million+ line codebase. And when we released there were zero bugs related to the upgrade.

Java has the stability keep projects maintainable over decades. The only mainstream language with comparable backwards compatibility is C.

Re: Java Is Underhyped

#640
post #395

Earlier quoted context omitted.

Your premise is that you are able to chose a language based on how appropriate it is for a specific use case. This alone shows you are not the typical user of Java! Java is typically used in larger or long-lived organizations. It is rare to start new projects from scratch. Most development is maintenance and extension of existing systems. Even if you start a greenfield project, it would be most prudent to chose the s…

> Even if you start a greenfield project, it would be most prudent to chose the same platform and language which is already used in the organization. Anecdotally, I see a trend of greenfield projects moving from Java to NodeJS. I can't think of too many organizations that have zero web presence, and basically any modern web presence requires the use of JS, so there's almost always some JS expertise built into the org…

Development is going the other way at my org. Our JS services quickly became "out of date", and nobody wants to put in the massive effort required to bring them up to modern JS language features, build tools, and libraries.

In contrast, our Java upgrades remain painless. Many of our JS services have been merged back into older Java back ends

Post reply on HN