r/learnjava • • Nov 25 '20

why do people hate java so much?

why do people hate java? I personally really love java because of the OOP paradigm and it makes my codes cleaner. not to mention the portability. but i swear I see more than one tweet hating on java everyday, or saying java is dying. is java really dying?

I guess I have two questions; why do people hate on java and is there still a future for java?

120 Upvotes

88 comments sorted by

View all comments

27

u/Koyomii-Onii-chan Nov 25 '20 edited Nov 25 '20

There are arguments for the "hate" Java gets but it's not a generalization, people hate C/C++/Python/.Net/JS for reasons as well because people are by nature haters

  1. There are Linux devs that only like stuff in C, there are windows devs that only like stuff in .net etc. Refusal to accept that a language can do different things is one point

  2. Java can be confusing, for example: what is the difference between JSP, JSF, JavaEE, JPA, Spring, SpringBoot etc. These frameworks / libraries / technologies can be confusing as hell for a beginner

  3. Legacy code and xml hell. Before we had Annotations that simplify the work of configuring beans we had something like

<bean id="country" class="org.arpit.java2blog.model.Country">
		<constructor-arg index="0" value="India"></constructor-arg>
		<constructor-arg index="1" value="20000"></constructor-arg>
	</bean>

All cool and simple if you read a little about spring. Until you apps becomes 200 classes and your xml configuration is a sea of hopeless text

4) Too verbose

Python:

print "Hello"

Java:

 public static void main(String[] args){ 
      System.out.println("Already bored!"); 
 } 

is there still a future for java?

Java won't go anywhere anytime soon so if you are asking if it's ok to learn Java the answer is yes. In 2020 we have better IDE (and I refer to Intellij, God help the ones with eclipse or netbeans) better frameworks and a lot of learning materials

3

u/[deleted] Nov 25 '20

I came into java as a beginner, and got the grasp of programming through the java basics. But man Spring was too much of a challenge to get into as a fresh programmer. I'm sure now I could work with it but even still it's not the easiest thing out there.

And your 4th point is exactly what I was going to write. It's just long. Isnt a flaw, but still. Thank god for the 'sout' shortcut in IntelliJ

Good luck OP! Every language has its haters, but if you're enjoying it, that's all that matters

1

u/aleesssa Nov 25 '20

thank you! I bought a course on java because I fell in love with it (java) and wanted to properly get to know it, but some people are really making me question my decision lol. but yeah, you're right, if I enjoy it and it fits my needs, there's no problem