I don't know about rust but I think kotlin is better in terms of development experience and most of the time kotlin code is concise and shorter than java code.
Conciseness per se is pointless. Development productivity is only thing that matter when comparing Kotlin and Java. And Kotlin often is worse than Java in this regard. At least for backend development.
Do you have personal experience with this? I wonder if this will change with time as people adapt to using the language more. In my area, Kotlin jobs or even projects are still very rare unfortunately, so please elaborate.
This might change over the time, but odds are low since some issues are inherent to Kotlin as a language. Here is my answer on similar question with more details and my personal experience.
I should note, that many Java issues, which make people consider Kotlin, can be solved by adopting Pragmatic Functional Java in combination with Java 11 and up (especially Java 17).
Yes, but Kotlin was designed with this exact mentality. Java plus some features, minus some annoyances, basically.
While I assume that you can do most things in Rust, it is primarily a speed and memory safety focused language. Without garbage collection, I might add. That does not make Rust bad, obviously, but I genuinely don't see the point of this article.
Yes, and likely it's won't be much longer before Java 17 is supported. Spring is likely to take a year before going to 17. If it's not possible by then, it's going to be a major deal breaker. Originally people used Kotlin mostly because they were stuck on also JVM's with Android. Kotlin also has other compile targets, like native and js. But I think they are still used very little.
Despite all the differences between the two languages, Java and Kotlin are 100% interoperable. You can call Kotlin code from Java, and you can call Java code from Kotlin.
Not 100%, you can't call a coroutine from Java, and you can't use Java Code that contains records for the moment. But yes, it all runs on the JVM, as does Scala, Groovy and Clojure, which you could use all together in one app.
I don't know about rust but I think kotlin is better in terms of development experience and most of the time kotlin code is concise and shorter than java code.
Conciseness per se is pointless. Development productivity is only thing that matter when comparing Kotlin and Java. And Kotlin often is worse than Java in this regard. At least for backend development.
Do you have personal experience with this? I wonder if this will change with time as people adapt to using the language more. In my area, Kotlin jobs or even projects are still very rare unfortunately, so please elaborate.
This might change over the time, but odds are low since some issues are inherent to Kotlin as a language. Here is my answer on similar question with more details and my personal experience.
I should note, that many Java issues, which make people consider Kotlin, can be solved by adopting Pragmatic Functional Java in combination with Java 11 and up (especially Java 17).
Yes, but Kotlin was designed with this exact mentality. Java plus some features, minus some annoyances, basically.
While I assume that you can do most things in Rust, it is primarily a speed and memory safety focused language. Without garbage collection, I might add. That does not make Rust bad, obviously, but I genuinely don't see the point of this article.
And adding some other annoyances, like not being able to use Java 17 together with Kotlin at the moment.
Right.
I was actually wondering about that. Is Kotlin supposed to be compatible with Java in the future as well? If not, major RIP.
True.
Yes, and likely it's won't be much longer before Java 17 is supported. Spring is likely to take a year before going to 17. If it's not possible by then, it's going to be a major deal breaker. Originally people used Kotlin mostly because they were stuck on also JVM's with Android. Kotlin also has other compile targets, like native and js. But I think they are still used very little.
Despite all the differences between the two languages, Java and Kotlin are 100% interoperable. You can call Kotlin code from Java, and you can call Java code from Kotlin.
Not 100%, you can't call a coroutine from Java, and you can't use Java Code that contains records for the moment. But yes, it all runs on the JVM, as does Scala, Groovy and Clojure, which you could use all together in one app.
Seems you can use Java records with Kotlin (and even define them in Kotlin)
kotlinlang.org/docs/jvm-records.ht...