Live data from Hacker News

Java 25 officially released

mail.openjdk.org

81–90 of 260 posts

Re: Java 25 officially released

#81
post #39

More new programs should be written in Java/on the JVM. Most of the reasons Java dropped out of popularity no longer apply, and at this point it is an incredibly stable and mature ecosystem. I can come back to a Clojure program I wrote ten years ago and it runs great , meanwhile a TypeScript program I write 6 months ago requires a bunch of updating and cleanup.

Java's biggest risk towards continued adoption, by far, is the culture surrounding it - old Java programmers and old Java programs continue to be needlessly verbose, even if the language now has the tools (pretty much) to be as terse as other popular, modern languages.

It's an uphill battle, but it might just climb the hill because it's still such a behemoth.

Re: Java 25 officially released

#82
post #39

More new programs should be written in Java/on the JVM. Most of the reasons Java dropped out of popularity no longer apply, and at this point it is an incredibly stable and mature ecosystem. I can come back to a Clojure program I wrote ten years ago and it runs great , meanwhile a TypeScript program I write 6 months ago requires a bunch of updating and cleanup.

Oracle makes me too uneasy. Can I use Java without the worry of incurring Oracle's wrath? Maybe, if I make sure I use openjdk/jump through some hoops I'll be fine. Or, I could just use any other language and not have that worry looming over me. C# is right there if I want a java-like experience without the anxiety of Oracle breaking my kneecaps.

I don't know how to use java and not violate one of Oracle's EULAs. I could read about it and figure out how to do it safely, or I could just not use java. Java isn't essential (for greenfield projects). There's lots of good alternatives, so I'd rather do that.

Re: Java 25 officially released

#83
post #49

Nice to see "Vector API (Tenth Incubator)" - it should open possibility of doing low level vector maths much needed by machine learning toolkit in Java.

It's not that new though. It will probably only be frozen once value types arrive.

Re: Java 25 officially released

#84
post #69

It's a damn shame that project Valhalla still isn't finished. This would fix so much and open up java for better matrix math support

Project Valhalla is too big to land in just one release. Even if all changes to surface language and the JVM land, it's just the beginning for adding new optimizations.

Re: Java 25 officially released

#85
post #75

Earlier quoted context omitted.

> it's verbose and boring to use. Python code that follows traditional Python paradigms is called "Pythonic". Java code that follows Java paradigms is called "awful". To be fully transparent, I've never written Java professionally, only for a couple small hobby projects 10 years ago, plus some while in school, so my opinion isn't worth the pixels you're reading it on, but I look at most Java code with abject horror.…

It's a culture, not language thing. Here is a JSON parser implementation (part of PlantUML) that lacks endless levels of abstraction. https://github.com/plantuml/plantuml/blob/master/src/main/ja...

I'd argue culture solely defines the language.

Is there a full library ecosystem of stuff written like the json parser you shared, which is as complete as the enterprisey library ecosystem? Similarly, SO answers? LLM output? Tutorials? YouTube videos?

I think the answer is no.

It's the same problem with C#. Just adding alternate paradigms means nothing. The only thing that matters is how a majority of code in the ecosystem is structured. In java, that's enterprisey code. Most code is glue code, so you're forced into the majority pattern, lest you want to write endless wrappers...

On the other hand, while typescript supports a lot of the enterprisey nonsense similar to C#, the majority of the ecosystem is written with simple functions, callbacks and options objects. Not in an enterprisey way. I don't need to use decorators to use zod.

People that eschew enterprisey code and prefer simple code can't switch to java or c# until the whole culture changes, regardless of the kitchen sink of features either language adds.

Re: Java 25 officially released

#86

(not a Java developer, no dog in this fight) I'm not sure I like the module import system very much. I think `import *`-like constructions make code a bit easier to write, but much harder to read, especially for developers new to the language / codebase. C# and Nim love that style, and it makes them almost unreadable without a good IDE. Personally, I much prefer Python's "short aliases" style, e.g. `import torch.nn.f…

AFAIK it's mostly intended to make writing single source file programs easier.

Re: Java 25 officially released

#87
post #78
post #44

Earlier quoted context omitted.

Yeah, Java 9 was the Python 3 moment of the ecosystem, however it has been sorted out for ages.

Not comparable; Python 3 changed the source language. While for most programs complying with standard Java nothing had to be changed at all.

Yes it was, your Java 8 code won't compile in Java 9, if using anything that was removed or blocked due to the modules changes, library and runtime are part of the language.

A programming language isn't only grammar and semantics.

Re: Java 25 officially released

#88
post #82
post #39

More new programs should be written in Java/on the JVM. Most of the reasons Java dropped out of popularity no longer apply, and at this point it is an incredibly stable and mature ecosystem. I can come back to a Clojure program I wrote ten years ago and it runs great , meanwhile a TypeScript program I write 6 months ago requires a bunch of updating and cleanup.

Oracle makes me too uneasy. Can I use Java without the worry of incurring Oracle's wrath? Maybe, if I make sure I use openjdk/jump through some hoops I'll be fine. Or, I could just use any other language and not have that worry looming over me. C# is right there if I want a java-like experience without the anxiety of Oracle breaking my kneecaps. I don't know how to use java and not violate one of Oracle's EULAs. I co…

Just use OpenJDK (only downside is you have to upgrade every half year) or a distribution of another vendor (most people use Eclipse, or Red Hat if they already are Red Hats customers). It's really not as difficult as it is made out to be.

If you use Oracle's distribution of the JDK then you are an enterprise customer and should have the resources to deal with their license terms.

Re: Java 25 officially released

#89

Earlier quoted context omitted.

Neat, I wrote some swing apps back in the day that I've thought about resurrecting, but didn't want to have to do much modifying since they are mostly toys, though useful to me. I'm gonna give it a try!

Is Swing good now? Usually when people say Java is good now I assume they're not talking about Swing.

I wrote a swing app a long time ago (20+ years ago) that was used in operating theaters to register organs for transplantation. Swing has saved many lives since. Swing has been good enough for a long time.

Re: Java 25 officially released

#90
post #63
post #39

More new programs should be written in Java/on the JVM. Most of the reasons Java dropped out of popularity no longer apply, and at this point it is an incredibly stable and mature ecosystem. I can come back to a Clojure program I wrote ten years ago and it runs great , meanwhile a TypeScript program I write 6 months ago requires a bunch of updating and cleanup.

Java is hugely popular and widely used on large backend systems. I guess a lot of people here don't work on such systems? I'm always surprised when I see comments like the parent, since in my career exposure to Java is near-ubiquitous.

There has been a move in the past 8 years away from Java on the back end, notably to Go, by several large engineering organizations, which made the move, "motivated" by the example of companies like Google or by projects like Kubernetes, and seduced by the promises of a language simple to learn, build, and deploy.
Post reply on HN