r/programming • • Feb 22 '15

Java Makes Programmers Want To Do Absolutely Anything Else With Their Time

http://www.forbes.com/sites/quora/2015/02/21/java-makes-programmers-want-to-do-absolutely-anything-else-with-their-time/
35 Upvotes

636 comments sorted by

View all comments

219

u/aldo_reset Feb 22 '15 edited Feb 22 '15

Why do many software engineers not like Java?

They don't.

Seriously, I know it might be hard to believe, especially if you spend time reading reddit, HN or if you are subscribed to a few mailing-lists on the subject (which means you are part of a very tiny minority), but the bottom line is that the majority of Java developers is quite happy with Java.

If you are one of these bleeding edge developers who keep their knowledge current, are aware of Scala, Kotlin, Ceylon, Clojure or maybe even ML or Haskell, you are convinced that Java is an abomination and that certainly, all its users must absolutely hate it. And you are dead, dead wrong about that.

Before Java, we had C++, and if in the 1990-1995 period, you had interviewed C++ developers, you would probably have found out that a huge proportion of C++ developers absolutely hated programming in this language. Which set the stage for Java to take over in 1995.

I'm not seeing this today. There are no rabid mobs of developers with pitchforks massing at the gates and asking for a revolution. Java is respected for its productivity, its readability and its unbeatable fast path to getting things done in a way that's scalable and maintainable.

Which is why that it's not going to be replaced any time soon. Not by Scala, not by Kotlin, not by Ceylon. In a lustrum, maybe. But not in the near future.

Java is fine, it's liked, it's respected (for good and bad reasons) and it's going to be around for a very, very long time.

40

u/llogiq Feb 22 '15

I am one of those bleeding edge developers you mention, I know Lisp, ML, Haskell and am currently looking into Rust. And I'm also a Java developer, and quite happy with Java.

Java sucks at some points, yes, but not as hard as many think. For a lot of problems, it's actually quite capable, and the specific pain points some folks never tire to mention either can be worked around with little effort or don't impair productivity as much as they think anyway. Also, frankly, the tooling just rocks.

18

u/f2u Feb 22 '15

I am one of those bleeding edge developers you mention, I know Lisp, ML, Haskell

  • Lisp: 1960

  • ML: 1979

  • Caml: 1987

  • Haskell: 1990

It's funny that those are considered bleeding edge. And I picked the year of the first formal publication. In reality, even Haskell is several years older than the mature (read: old-fashioned) Java.

6

u/BobFloss Feb 22 '15

I guess it's more that those languages have seen increased popularity (and changes, probably) recently.

→ More replies (6)

12

u/yogthos Feb 22 '15

As one of those bleeding edge developers who developed Java professionally for a decade before moving to Clojure, I would not go back to working with Java.

My team saw a huge leap in productivity compared to the similar scope projects we've done in Java. The language does play a big role in this. Being able to write code close to the problem domain makes the code base much smaller and easier to maintain.

Having drastically less code has impact on things like refactoring. When it takes you a 100 lines to solve a problem you're not all that attached to the code. When it takes you a 1000 then you're much less likely to want to revisit it.

Being able to safely reason about parts of application in is a huge benefit when you're working on a large project with a team. I know that I can work on my piece and I'm guaranteed that it doesn't have any shared state with another piece somebody else is working on.

When I come back to some code 6 months down the road I know that the changes I make are guaranteed to be local. I don't have to remember how it interacts with the rest of the application, where the data is coming from and where it's going.

I also agree that tooling is important. I find REPL to be an indispensable tool. With it I can solve problems interactively and see exactly what the code is doing. Having it integrated into the workflow makes development a far more pleasant experience.

Aside from that, I find you have pretty much the same tooling you have for Java. You've got Leiningen or Maven for doing builds, you can use the same profilers, build servers, and deployment targets.

You can also use the same IDEs such as Eclipse or IntelliJ. The refactoring support might not be as powerful, but you also tend to have orders of magnitude less code. I'd much rather have less code to work with than fancy tools to help me manage giant heaps of it.

0

u/[deleted] Feb 22 '15

[deleted]

→ More replies (20)

2

u/llogiq Feb 22 '15

I usually whip up a quick unit test + debugger if I need to test something, but I also sometimes just start a beanshell.

→ More replies (5)
→ More replies (14)

57

u/[deleted] Feb 22 '15

I've always maintained that HN and Reddit over represents the startup mentality in almost everything. In reality a ton of Java is written (if you asked around here everyone would think that Java is legacy only), and it seems to be working just fine.

Eventually it'll go, of course. It'd be foolisg to say that Java is it, but there's not a ton of evidence that the time is now.

24

u/continuational Feb 22 '15

It over represents opinions from people who care enough about their profession to browse /r/programming. These are the same people who are dissatisfied with working in poor languages. People who don't care would rather stay with whatever they already know.

13

u/armornick Feb 22 '15

People who don't care would rather stay with whatever they already know.

Or stay with what you're being paid to use. Because I like other languages too, but I only get paid to use Java.

→ More replies (5)

3

u/ameoba Feb 23 '15

Reddit overemphasizes the opinions of young, inexperienced people.

→ More replies (4)

2

u/argv_minus_one Feb 22 '15

There is no such thing as "it". As long as computer science exists, new languages will keep getting invented.

→ More replies (9)

14

u/vincentk Feb 22 '15

I'm one of those bleeding edge developers, and believe it or not, I'm still quite happy with java.

2

u/[deleted] Feb 22 '15

Same here, latest fun language has been purescript.

4

u/htuhola Feb 22 '15

I hoped to see a large-scale interview when I saw the title. Without that you can't really say whether java developers are happy with their language or not.

Looking on Reddit I see people advocating about all kinds of languages. You'll find APL, C, C++, PHP, Fortran lovers. Wouldn't be surprised if somebody says he loves cobol or basic.

You probably can't know if people hated C++ in the 1990-1995 period, similar to how you can't know if people hate java now. We don't have the data to drive those conclusion. Besides you've pretty much proved this far that such study couldn't lead us to other conclusions. Popularity of a programming language isn't rooted into it's quality.

I'm surprised to hear that you respect java for it's productivity and readability, though. But maybe you're doing so simple things that it works out.

4

u/joequin Feb 22 '15

I think it's extremely readable, because unlike functional languages and newer languages it doesn't encourage the cleverness that often impedes code readability.

3

u/kcuf Feb 22 '15

Layering several abstractions, spread across various files/packages, just to achieve future maintainability impairs readability. Shared mutable state impairs understanding, and thus readability.

→ More replies (10)
→ More replies (4)

0

u/[deleted] Feb 22 '15

[deleted]

15

u/unruly_mattress Feb 22 '15

Which other languages do you know?

5

u/aradil Feb 22 '15

I like Java, but I never use it on my personal projects. I like C# but I'd I'd never pay for the licenses needed to run it for personal projects and Mono isn't quite there yet.

I dislike PHP but it's up and running in seconds, so it gets the call up often. I've dabbled with python but the latest major release fucked everything and now it's like there are two languages and the documentation and libraries are only sort of correct now.

I think for my next big non-scripted project I'm going to try out Scala.

5

u/aijoe Feb 22 '15

I like C# but I'd I'd never pay for the licenses needed to run it for personal projects and Mono isn't quite there yet.

Just curious but since you don't mean Mono here(or xamarin thats based on it) what do you mean by needing to pay for licenses to run C#?

→ More replies (36)
→ More replies (10)

0

u/[deleted] Feb 22 '15

[deleted]

6

u/streamlin3d Feb 22 '15

Not necessarily for productive use, but you could take a look at Haskell or ML. I found it quite interesting to get into this totally different way of thinking when programming, although I never used it in RL (yet).

→ More replies (2)
→ More replies (1)
→ More replies (1)

6

u/drysart Feb 22 '15

but the bottom line is that the majority of Java developers is quite happy with Java

I have a feeling that's because developers that know there are better environments out there get jobs where they don't have to write Java.

→ More replies (107)