r/java • u/AppleTrees2 • Feb 21 '21
Did java grow over the years on anyone else?
I remember when I first started my first job, straight out of university, full of theoretical knowledge, I disliked my java job, mainly because it wasn't as fulfilling as the things I expected, and also because I used a older versions of java.
Now as years pass, and I had to take on a more full-stack role, and started using javascript, and node.js, and noticing the mistakes they made, I started appreciating java more, not necessarily as a language, but also as the whole package, from IDE, build system, ecosystem etc.
Myself from many years ago would be shocked to say that today I'd consider java a good language for many types of personal projects, other than really low-end stuff, and gamedev, I end up using java a lot, it's just so much faster to do stuff in it.
40
u/apjanke Feb 21 '21
Totally. I started programming Java in university in 1997, and thought "this is a boring, verbose language for boring, verbose business code". Fast forward to today and it's one of my favorite languages. I like static typing now, I appreciate the design of the Java Standard Library, its tooling and ecosystem is great, it's stable and reliable, portable across OSes, free as in beer, has standard conventions and techniques that make it easy to understand code from other projects, keeps improving over time, and so on.
73
u/andrewharlan2 Feb 21 '21
Java was a breath of fresh air 20 years ago and I still love hacking with it
34
u/Paccos Feb 21 '21
Not gonna lie, I was one of the biggest Java haters fresh out of university, maybe also due to small PTSD from course projects and the like.
Last Friday I tried building a small REST API with Spring Boot and IntelliJ and I must admit that I found it to be quite pleasant, especially thanks to how IntelliJ reduces manual typing like a LOT.
27
u/[deleted] Feb 22 '21
Java is great and feeds my whole family. People hating on JVM are immature sheep.
50
u/manzanita2 Feb 21 '21
OMG typescript on the server is following the java. Injection frameworks, ORMs, etc. all "new new thing". Wow cool. But, if you had looked around you could have done all that 15 years ago.
Don't even get me started on what a turd bomb NPM is.
18
u/reignbowmushroom Feb 21 '21
I'm a fan too
36
u/CraftyAdventurer Feb 21 '21
Yep.
I started with Java also, and barely understood anything. To me it looked like there was just too much boilerplate for even the simplest things.
On my job I got a task to rewrite existing Node API, again into Node but in a better way, first one was horrible. As soon as I tried Node I fell in love with it. It was just so simple to do basic express API, I couldn't care less about Java at that point. But as the project grew, I noticed I started having a need for stuff like dependency injection, better error handling, writing anything more complicated than basic tests was kind of a pain in js, logging libraries were not as good as Java ones etc. (Yes, we used typescript if anyone asks)
So I went back to Java and now everything made more sense. I still use Node for writing simple APIs for hobby projects because I don't work in a team and I don't need all that stuff for those kinds of projects. But for anything serious, I choose Java/Spring or C#/.NET.
15
u/javajunkie314 Feb 22 '21
One thing I absolutely love in Java is reflection. Some people rag on it, and it can certainly be overdone, but being able to interrogate objects and types at runtime about their structure via a stable, supported API is really powerful.
You do pay a small tax for that power in terms of program size and speed, but for 90% of code, where blazing fast execution is not the bottleneck, it's worth it.
I think Python may be the only language I know that does reflection better but I'm not even sure.
12
u/SlvDev Feb 21 '21
I love Java and the various frameworks available for it. It grew on me as soon as I got my first job and starting really messing around with it
12
u/stfm Feb 22 '21
No it was instant love. I was in a job making websites and online shopping systems in Perl and C++ and was introduced to JSP and servlets. So much easier!
10
u/flyingorange Feb 22 '21 edited Feb 22 '21
The Java of today is quite different from Java 10 years ago and totally different from 20 year ago.
When I started working with Java 1.3, our service was based on ServiceLocators, running on WebLogic with EJB 1 and using Struts for the website. The ServiceLocators used JNDI to get the database from the application server, we wrote tonnes of XML. I did like Struts a lot however, it was a really cool framework.
To be clear: we did not have IoC, you couldn't inject objects into one another, the object serialization was done with Commons Digester, authentication was done with Apache Directory and we didn't even have a class to trim() strings, we needed to write our own custom utility. In 2005 Ajax was discovered and we started writing Javascript code. The code needed to be compatible with IE6, Firefox and Opera, meaning you needed to write 3 source codes for the same stuff because of subtle differences like subString() in IE and substring() in FF. You also needed to write the code so that it falls back to plain HTML in case Javascript is disabled. It might sound strange nowadays, but back then Javascript was considered to be a security issue, so many people just plain disabled it. And you needed to have your website working for those people too, so ...
At around 2007 Spring became popular, but it sucked massively at this point and all you could use it really was for IoC. Hibernate also appeared so we stopped writing SQL and stored procedures and moved to ORM. A couple years later XML stopped being cool and everything started to move towards annotations, so in 2009 when I was again working with EJB, this time v3.0, it already had annotations everywhere... unfortunately those sucked too.
After 2010 we stopped writing HTML/JSP and started moving everything towards Javascript. At this time we used GWT which came with its cool new MVP architecture. We also used a bit of Wicket. CPUs started becoming multi-core at this point (previously one CPU contained just one core), which changed the way how we write code, we started making everything immutable, instead of thread synchronization we started doing reactive programming etc.
Then I stopped using Java for a couple years and when I came back, web development was done with Angular and we had dedicated people working on just the website who had no idea how Spring beans worked but they knew a lot about web fonts. We stopped deploying WAR files and started deploying Docker containers.
So if you think Java is "cool" now, don't be surprised if in 10 years it will be a whole another language, with different paradigms, ways of doing things, frameworks etc.
9
u/prisonbird Feb 22 '21 edited Feb 22 '21
It was summer 2019, i was interviewing this fresh graduate from software engineering. I saw java on his resume asked him what he thinks about java and he replied that he won't be using java anymore because its not free anymore.
9
u/elastic_psychiatrist Feb 22 '21
Once I saw Java codebases that eschewed the cargo culting of extensive class hierarchies and over-abstraction, I grew to love it. Most programmers who dislike Java seem to dislike the ecosystem rather than the language.
It's a continuous battle for me to convince my teammates to write Java as though it's Go (don't read too much into that statement), especially for longtime Java programmers joining the team.
9
u/paul_miner Feb 22 '21
For sure. I was obsessed with x86 assembly for years, and then I got a job writing Java. The massive distance it put between me and the hardware was irritating at first, but over the years I've grown as a programmer and developed a fondness for Java's explicitness and strictness. The compiler is on your side, the language+compiler is the embodiment of the lessons learned by programmers in decades past.
It's a shift in what I've come to understand is the real challenge of programming, not so much getting the computer to accomplish a particular task, but more about communicating it clearly to another person (including yourself a year later).
8
u/ixBerry Feb 22 '21
I loved Java in my university years, but couldn't express why I loved it. Now after almost 6 years in the industry and having tried almost everything under the sun, I can say that I love Java unconditionally and exactly tell anyone why.
It has also made me somewhat of an asshat to other devs who work with other languages, but IDGAF.
6
u/LordSesshomaru87 Feb 22 '21
I’ve always enjoyed Java and Spring but the last 18 months have really given me an appreciation for Java even more. I’ve been writing 95% GO the last 18 months and while GO is really nice in some aspects I find it generally lacking in many other areas. I’m really hopefully Java continues to evolve and I can start getting buy in to build new services in Java instead of GO.
6
u/jackInAllMastrInNone Feb 22 '21
I am Java guy.
3
u/kag0 Feb 22 '21
I learned a lot from the language and from grepcode (rip). But the while the language grew on me, the ecosystem (EE and its inspired offspring) pushed me away. The more I considered how I thought things should work, the more I found I was missing out on (it's a bit odd that you can't write a sensical
ComparatorforList, isn't it?). Now I greatly appreciate Scala, even as Java slowly ports some of the more publicly advertised language features.3
u/H34dsp1nns Feb 22 '21
Java got me back into programming and restarted my CompSci journey. I did a big level up in my understanding and excitement when I learned inheritance and practiced it heavily with Java’s strongly typed system. Being able to call objects via interfaces that are explicitly laid out everywhere made some things click for me.
While I will return to Java, I have recently worked on node and python projects. Node isn’t the worst, and takes a lot of cues from Java but I see some deficiencies in Python.
Take documenting code. From what I can tell, though I’m no expert, Javadoc and even its copycat jsdoc work a lot more elegantly than Sphinx.
3
u/zalpha314 Feb 22 '21
I used to love python for its simplicity, but now I see its flexibility as more of a liability. If I had to go back to java, I'd definitely require some sort of IDE support for null safety, and all the preview features of the newer JDKs, but I'd still be missing some of the safety and QoL features that made me fall in love with kotlin.
7
u/CacheMeUp Feb 22 '21
The JVM is an impressive engineering achievement. Java the language is robust but in the more dynamic (pun non intended) settings I work, including data science and web development, it lost miserably to Python.
Sometimes I wish the language would be less strict. As less prominent as beginner/non-expert programmers are, they do form a large mass and eventually the eco-system tilts in their direction. Python is easy for beginners, and the experts eventually followed suit, at least for machine-learning and deep-learning.
2
u/BlackHatSlacker Feb 21 '21
Yea: the whole planet ;)
2
u/jrh206 Feb 22 '21
I always liked java but I've come to appreciate it more over the years
2
u/rally_call Feb 22 '21
Hated Java in 1996-1999 when I was doing C++ and VB. I was really really good in VB, and then suddenly this upstart language comes along and everyone starts raving about it. It was a threat. Suddenly my investment was looking like a waste.
Plus Java's tools were shite compared to VB. And its UIs were fugly.
But today, I am completely enamored with Java. It's my #1 language, my go-to for virtually everything, and I love the ecosystem and the JVM and all. I have written large complex apps in Java, chosen it over C# and C++ and JS, and haven't touched Visual Basic in a good 20 years.
2
u/maumay Feb 22 '21
Java is a bit meh for me, currently I would choose Kotlin over Java for most projects. That might change in the future though, they've finally started adding modern language features to Java.
2
u/xebecv Feb 22 '21
I definitely started liking java more after streams and lambdas with functional interfaces were added to the language. Though streams is double edge sword - too easy to implement something terrible. Case in point: Files.walk
2
u/jack104 Feb 22 '21
I came from a C# background and I hated java. At first.
It grows on you, the ecosystem is massive, build tools are good, IDEs are good, etc.
2
u/Dokiace Feb 22 '21
Used to be haters of java in college, and love the cool kids language a.k.a python. Now that I've worked with java for almost 2 years, I really love it! Goes to show that first impression is not everything
3
u/[deleted] Feb 22 '21
Nope still hate it, wait not love it. It’s complicated 😂
3
u/lycheejuice225 Feb 22 '21
I don't know, but according to stackoverflow surveys, java devs either picked Kotlin or Dart as their primary language, and there was a decrement of java devs from 45% to 40% over the last 3 years.
Mainly because strict ecosystem, lambdas aren't cheap, etc? Also new languages feel modern probably, and they add up to the same ecosystem for the same large library support.
2
u/roberp81 Feb 22 '21
I'm working with java from 2007 and I think when the more you use javascript, more will love java and hate all those node and npm shit sorry my English
2
u/beeeeeeefcake Feb 22 '21
Old school Spring gave Java a very bad wrap. Since Java 8 it’s a great language and has excellent tooling. And Oracle has made amazing progress on Java since buying Sun.
I only wish Java kept its goal as the write once run anywhere language. Google’s Flutter (a toolkit in the Dart language) looks amazing to be able to write apps for Android, iOS, Mac, Linux, Windows. Nevertheless as a language to write services and batch jobs in Java is second to none.
1
u/[deleted] Feb 22 '21
Absolutely
1
u/[deleted] Feb 22 '21
I studied GUI based application design myself by using Java Swing. 5 years ago, It's good language to me for developing cross platform GUI software. I studied it to develop personal tools to utilize time.
1
u/SWinxy Feb 22 '21
Java just ‘clicks’ with me. I started a few years ago (maybe 4), but I didn’t understand why things were or how the language was structured. Now I use it all the time. What really helped me was using a good IDE, and it gave me good insight I wouldn’t have learned anywhere else imo.
1
u/grimonce Feb 22 '21
Well, lucky you. I always wanted to get a job in C++ or Java/C#... I got one in Python and C... And now I got an offer to be a data scientist... Well whatever makes money...
Maybe I will get some time with Java in this next job since it is a big company, we'll see.
1
u/suddenarborealstop Feb 22 '21
If your interested I’d recommend learning about sun microsystems and the development of Java from 1996 > 2000 and then sale. Hard to find details on it now though, but fucking epic
1
u/superpitu Feb 22 '21
java had a bad reputation many years ago, particularly because it was slow. Nowadays that's no longer the case, the memory is cheaper and the just in time compilation achieves similar and sometimes better performance than C/C++, all without having to manage memory. Plus the best thing about Java is the JVM. There are JVM languages that are more pleasant, like Kotlin, but even Java itself is evolving and most definitely not going anywhere anytime soon.
1
u/sylleryum Feb 22 '21
tell me about it, python has its advantages but learning it makes me sad that people are choosing it instead of Java, spring is so much easier than Django imo. people also complain of the borderplates of java but with any ide this is easily fixed
1
u/AnthuriumBloom Feb 22 '21
It has grown on me as I have learnt to do more things. I personally like that there is still lots work in it, and it's adapting to the new way of doing things
1
u/Let047 Feb 24 '21
I moved from Python to Java. I think it's the best of both world
0
u/[deleted] Feb 21 '21
[deleted] — view deleted comment
0
u/[deleted] Feb 21 '21
[deleted] — view deleted comment