Live data from Hacker News

Java 21 makes me like Java again

wscp.dev

281–290 of 777 posts

Re: Java 21 makes me like Java again

#281

Sad this gets to front page while a blog post which documents that .NET 8 has 200 A4 pages worth of performance improvements gets absolutely ignored. C# keeps being the language people are looking for but don't know about.

> C# keeps being the language people are looking for but don't know about.

Every time I point out about C# most programmers are saying about evil Microsoft and being locked in the ecosystem. Most programmers I've met do not even know that .NET Core is MIT open-source and runs on any device.

I really wish C# would be more widely used because it is amazing, and for sure 10 times better then Java.

Re: Java 21 makes me like Java again

#282
post #277
post #3

In other news, we have an upgrade path at work to go from Java 8 to Java 11 pretty soon.

What were the backward incompatibilities preventing that move? I thought Java was pretty backward compatible, but I've heard this a lot.

It's more likely that there's some dependency that is not easy to upgrade, because the upgrade also includes api changes (from the dependency, not from the jdk).

Compound this with multiple dependencies that exhibit this issue. If you have a "legacy" application that does not require active development, there's zero business incentive to invest into the upgrade. Unless you could prove value in having the upgrade, it just doesn't get prioritized.

Re: Java 21 makes me like Java again

#283

Sad this gets to front page while a blog post which documents that .NET 8 has 200 A4 pages worth of performance improvements gets absolutely ignored. C# keeps being the language people are looking for but don't know about.

Its a good language, but the corporate sponsor and community is suspect. Microsoft has a long history of user hostile actions. The types of companies that use C# often treat SWE as second class. Learning and using C# limits career options to low salary, high stress jobs.

Re: Java 21 makes me like Java again

#284
post #22
post #3

In other news, we have an upgrade path at work to go from Java 8 to Java 11 pretty soon.

do/i/still/need/to/create/sub/directories/for/the/things/i/want/namespace?

better_than_having_just_a_single_file_that_have_lots_of_functions_without_namespacing

Re: Java 21 makes me like Java again

#285
post #73

[flagged]

Having worked extensively in Java, Node, and Python, I’ll take the JVM ecosystem absolutely any day of the week. Me and my catheter will be over here delivering actual software while you figure out how React 32 broke your transcompiler.

> delivering actual software while you figure out how React 32 broke your transcompiler.

Say that to enterprise software systems still running on Java 7 or 8 without any clear path to upgrade because their whole systems will break.

Re: Java 21 makes me like Java again

#286

Earlier quoted context omitted.

I don't think any existing Go developer is going back to Java. I worked with Java for 10 years and switched to Go and I will never go back. This is mostly because applications and libraries are so hard to reason about and understand due to inheritance, packaging, OOP, build tools ect compared to Go. Go is simple. It's easy to understand, read, and maintain. The packaging is like how you would package files on your co…

Go's major selling point to me is that you can ship one binary, nothing beats that. Python, Node, Java all have to pre-install lots of dependencies before you can use them, fine for developers, not so great if you want to distribute software for people who are not software savvy, who typically just wants to download one file, install and start using it. c and c++ can also do one executable, but, it is not as portable…

Since Java 9, developers can use jlink to provide a pre-packaged runtime environment bundled with the application. It's not static-link friendly or a single executable, but it does not require the user to pre-install anything or pull dependencies at runtime.

Re: Java 21 makes me like Java again

#287

Earlier quoted context omitted.

I don't think any existing Go developer is going back to Java. I worked with Java for 10 years and switched to Go and I will never go back. This is mostly because applications and libraries are so hard to reason about and understand due to inheritance, packaging, OOP, build tools ect compared to Go. Go is simple. It's easy to understand, read, and maintain. The packaging is like how you would package files on your co…

Go's major selling point to me is that you can ship one binary, nothing beats that. Python, Node, Java all have to pre-install lots of dependencies before you can use them, fine for developers, not so great if you want to distribute software for people who are not software savvy, who typically just wants to download one file, install and start using it. c and c++ can also do one executable, but, it is not as portable…

You mentioned "distribute software" but did not consider Electron for Node.

You can make an Electron app with JavaScript and ship the binary (or installer) on any platform. It's not a single executable file, but the user experience is the same.

I don't think there's an equivalent in Go that allows you build a desktop app like that (with frontend and backend both written in Go)?

Re: Java 21 makes me like Java again

#288

> This set of changes allows Java to express one of the foundations of functional programming that the language never could before - Algebraic data types, along with idiomatic ways of using them. And here I thought the foundation of functional programming was functions , which Java still doesn't have. Seriously, functional programming is about functions, not types.

> functional programming is about functions

different people mean different things when referring to functional programming.

Some people believe that functional programming are using higher-order functions like `map`, `reduce`, `forEach`, etc, which takes a function as a parameter, instead of doing imperative loops.

Some people, in addition to above, believe that functional programming is about creating functions that take a certain 'shaped' parameters, to allow for automatic checking.

And lastly, the "real" functional programmers are people who believe in referential transparency in your functional program.

Re: Java 21 makes me like Java again

#289

Sad this gets to front page while a blog post which documents that .NET 8 has 200 A4 pages worth of performance improvements gets absolutely ignored. C# keeps being the language people are looking for but don't know about.

We live in bubbles.

In my limited 6 years of professional experience as a software engineer, I have never met a single person who writes C# or .NET.

Re: Java 21 makes me like Java again

#290

Can you convince me to use Java? I’ve never used it (only C++, Python, CL) but it feels bloated and dirty.

Java itself is a nice language that can be lean and mean but has long been culturally bloated by early tooling and conventions. Since Java 8 (~10 years) the tide has reversed and it now mostly accepted to write terse code that is to the point.

The language gets updated regularly and is managed very competently. Although it may seem to trail on some aspects vs other langs, it benefits from second mover advantage - new features are done right, for the right reasons.

Any Java code ever written is essentially eternal, both in text and compiled bytecode form. Compiler and VM compatibility guarantees are unmatched. You can stumble upon 20 year old code and just use it.

The platform is mature and robust. The JVM itself is a marvel of engineering.

The ecosystem is extremely rich. There isn't a problem that wasn't addressed by a library or a stack overflow question.

The tooling is unequalled. IDEs can reliably perform large code transformations because there is no preprocessor or macros and the type system is relatively sane.

If you know Java you'll never be out of a job.

Post reply on HN