There is no greater sin than to say something positive about Java on the orange site... IMO Java and C# and other compiled languages have the opposite problem with languages like python and JavaScript (I love all these languages btw). It’s easy to get up and running quickly with the latter. It’s not until your project has grown in complexity when the formers value becomes apparent. This is similar to mongodb vs say,…
Java Is Underhyped
541–550 of 808 posts
Re: Java Is Underhyped
#542This post from "an ignorant computer science undergrad" is pretty silly, so allow me to get a little silly in response. I think if Java's new features are an attempt to woo new developers, Java comes off pretty tragically, like the old guy in the club, trying stay relevant by showing off how it just got up to date with ideas that hit the mainstream ten years ago. Whoa, check out these record classes! Fresh stuff over…
I’ve kinda started to like Kotlin from syntax perspective & Go’s nature of compiled and low overhead prospective. I wish somebody can combine those together (don’t tell me GraalVM).
Re: Java Is Underhyped
#543For 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…
My main issue is that people writing Java (or for the JVM) because of their backgrounds (app-level code printers) almost completely disregard how that code works on the JVM, at scale, in a highly responsive and/or high throughput service. You can't just use a big, "safe bet" framework like spring, which taints EVERYTHING in that project, write a simple REST API and then do heavy work "in the background" without side…
Re: Java Is Underhyped
#544Earlier quoted context omitted.
I am sorry, Go? That can’t be right. I even doubt it’s any more verbose than python or swift. You CAN make it verbose that’s for sure.
> You CAN make it verbose that’s for sure. No true scotsman? Even if you want to argue that Java CAN be made more terse, the vast majority of Java that exists today is incredibly verbose. Even running a Java program is verbose. Java is the only language I've used where it's more common to have a shell script that starts your Java program than just running ./helloworld. And yes, Go is less verbose than Java. Go might…
Re: Java Is Underhyped
#545Earlier quoted context omitted.
>the Python community is at least half composed of amateurs. or, even worse, scientists.
And most recently, tons of self styled "Data scientists". This has, IMO, diluted the rabid rhetoric of the 90's/oughties python community which is good, but replaced it with people who don't know and don't care what good code even looks like, so it can be difficult to work among them.
The previous crowd with love for monkeypatching everything and hate for abstraction other than dictionaries wasn't too pleasant, too.
Re: Java Is Underhyped
#546Earlier quoted context omitted.
I can (and often do) build from CLI, that is much smoother. I tried using vim on java, but honestly you need an IDE for all the constant code generation and incessant fixups by mouseclicks that are needed. Vim+coc is more than enough in the other languages that I use.
You're living in a parallel universe from the rest of us. IDE isn't necessary (and positively odd) for building Java.
Re: Java Is Underhyped
#547However, it's the culture around Java that I hate, and that's the reason I avoid Java. The amount of low quality Java code out there is staggering. The culture around Java is one of extreme levels of abstraction and encapsulation, and it makes reasoning about Java code really painful some times. If you have worked in a Java shop, check out the Enterprise edition of FizzBuzz: https://github.com/EnterpriseQualityCoding/FizzBuzzEnterpris...
Re: Java Is Underhyped
#548Earlier quoted context omitted.
It is, but if all you want is a JVM, Java is still probably the worse choice over Scala or Kotlin
The exact opposite is true. Scala's and Kotlin's syntactic sugar comes with tonnes of overhead and additional allocation. Java is pretty raw compared to them and allows you to stay closer to the C-spirit and thus retain more control over the side effects of the code you write.
I haven't seen any benchmarks, but I doubt a Scala app written idiomatic style would be any slower than the Java version written in idiomatic style.
Also, what is this C spirit we are trying to stay close to? I'm certainly not interested in any "C spirit"
Re: Java Is Underhyped
#549Earlier quoted context omitted.
It's horses for courses. Some plus points for Java: - 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). - the syntax, although not the most succinct is fairly easily readable and maintainable by other developers.
> - 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…
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 would be hard pressed to find many languages that continue to manage at the scale Java apps routinely handle.
Yeah, it’s (typical business monstrosity) hard to understand, probably has many thousands hours of technical debt, but it just works, and more things can be added to it (and occasionally with much more work, removed as well).
Re: Java Is Underhyped
#550Earlier quoted context omitted.
I think Kotlin is pretty much what a modernized Java should be. Between it and Clojure I don't spend very much time with Java anymore.
Kotlin could he better, but doesn't go all the way. Without HKTs and implicit injection, Java is going to eat its lunch. Java already has records, type inference, parametric null safety with Optional, Loom provides coroutines, vavr and streaming apis have given us theabilitytodo FP... what's left as a unique feature? Kotlin will survive because it was picked for Android to avoid copyright issues. But the difference b…