Hacker News new | ask | show | jobs
by jillesvangurp 707 days ago
Actually, I use Kotlin in a browser using Kotlin multi platform. Things are changing rapidly and you can do a lot without any Java libraries whatsoever at this point. The multiplatform ecosystem is growing very rapidly now.

Also, you might want to read up on how Amazon, Google, Facebook and other companies are moving to Kotlin internally at scale for server side use. They've been pretty vocal about that. A lot of Java shops are of course a bit glacial in their adoption of new technology. That's why I refer to it as the new Cobol. That has less to do with the language and more to do that this kind of companies simply don't change very easily. You'll find some actual Cobol lurking in a lot of these companies as well probably.

Kotlin was originally developed to be a drop in replacement for Java in any Java project. Android developers embraced it in a hurry because they were stuck with a relatively old and crappy version of Java because of the whole Oracle law suit with Google. Google made that official shortly after Kotlin 1.0 released acknowledging that many Android developers were voting with their feet at that point already. They also just embraced Kotlin multi platform at Google IO a few months ago.

On the server side, people have been using Kotlin for about as long. But things move more slowly there. Spring launched their Kotlin support around Spring Boot 2.0. That's six years ago already. It worked fine before that but that's the moment they started shipping lots of out of the box Kotlin support. Frankly, if you are using Spring and not using Kotlin, you're missing out big time. Lots of companies of course insist on doing things the verbose and hard way with Java.

1 comments

Snow flake hyperscallers, with vouched interest in Android ecosystem, aren't the same as everyone else.

The Oracle excuse is bonkers, everything on Android depends on JVM, written in Java, and Maven Central libraries, written in Java.

If Oracle actually played a role they would have switched Android to Dart and Flutter.

Kotlin was adopted by some management folks on Android team that are Kotlin heads, and to this day most Android documentation samples use Java 8 as counterexamples to how Kotlin makes things better, completely dishonest.

Looking forward to see JetBrains shown off their ecosystem rewrite in Kotlin Native, showing the rest of the world how Java is so passé.

I'm not sure what you are going on about here. Around the time Kotlin launched, Java was on version 8 and most of the Android world was still stuck with version 6 and missing out on quite a bit of nice stuff that came with newer versions. The Oracle dispute was specifically about Google's implementation of Java on top of Apache Harmony (developed by IBM orginally) which was an alternative implementation of the Java standard library. Since the dispute was resolved they transitioned to basing their libraries on OpenJDK and these days are a bit more up to date.

Anyway, Kotlin came along as that was still in the courts. Google understandably wasn't putting a lot of effort in updating the compiler or the core Java libraries. With Kotlin, developers gained access to a lot of modern language features.

So, not bonkers but well documented history. If you want to try your compose apps on IOS, you can now. It's currently in Alpha release. Zero java libraries running on that platform. All Kotlin multi-platform backed by IOS native.

As for Kotlin getting endorsed by Google. That wasn't management doing anything other than responding to a lot of Android developers enthusiastically adopting Kotlin long before it was even releases properly and getting some good results. App development is super competitive and developers aren't afraid to try out new stuff if it gives them an edge. And Kotlin did exactly that.

Between that and the Oracle dispute, it was a logical move for Google to make it official. In the same way Jetbrains move to push kotlin multiplatform and compose multiplatform originated outside of Google. And is now getting endorsed by Google as well. I guess the compose team and the flutter team are in different parts of the org chart.

Yet in 2024, the anti-Java speech with Java 8 samples continues, and they only updated ART to Java 17 LTS, because Android was losing out on Modern Java ecosystem.

While using Android Studio, Gradle, Android SDK, Kotlin compiler, D8, R8, all running on top of Java Virtual Machine, using Java libraries from Maven Central.

So much for breaking free from Oracle.