r/learnjava • u/[deleted] • Aug 20 '21
Where is Java most useful today? Where does it shine? (2021)
I've been learning core java for a month or two now because my dad insisted that it is very flexible and thatit's what they use at work, but ever since I neared the end of different free courses and youtube playlists, I don't know where to go. I know it can be used in a lot of things like web, games, and android dev, etc... but isn't there better tools for that now that are easier to use? Like, how I learned basic front-end web development earlier this year using html, css, js. There's Kotlin for android and react native can be used to make mobile applications. I also thought of game development but isn't swing and javaFX kinda outdated?(I'm not sure, I get mixed responses from google and forums), and now we have Unity and others.
I'm kinda stuck right now, but maybe I am just underestimating java in these different fields because of my endless internet browsing about it? Any advice or opinions?
28
u/wodahs1 Aug 20 '21
Definitely backend web services like Spring apps that make use of Kafka and AWS, GCP, Azure SDKs for Java
10
u/Stack_Canary Aug 20 '21
Java is very nice for virtually all kinds of backend services, and is widely used. Kotlin and Java live in the same "sphere" and both run on the JVM. You could learn Kotlin without knowing Java, but they are definitely related, and at least in my opinion you would get more out of Kotlin if you have a basis in Java, as Kotlin aims to solve some of the Java hurdles while still living in the same ecosystem (you can have a project with both kotlin and java files). If I were to point out where Java really shines these days it is Webservices with Spring Boot. Easy to make and maintain a Java environment of REST backends.
Frontend (html, css, js) is a different domain. Java is not used for web frontends. However, it is commonly used for desktop applications, although I personally feel this is not where it is most useful - there are other languages that do this just as well.
Game development is possible with Java, but is typically done with C# or C++ AFAIK, mostly because Unity is widely used and supported these days.
5
u/Stack_Canary Aug 20 '21
A little correction: It is not -commonly- used for web frontends, but you have JSP. However, this is becoming outdated and basically sucks to work with.
Another note: Kotlin is the go-to and suggested language for Android development, but you can just as well use Java because of the interoperability I mentioned.
9
u/khooke Aug 20 '21
Learn Spring, Spring Boot, then build some REST apis. Pick a major cloud platform, create an account then learn about deploying and running them in the cloud.
5
u/aeternum123 Aug 20 '21
A lot of the backend automated processing at my current job is written in Java. Our website uses GWT and Java. A lot of our internal application (websites) use Java and jetty or tomcat. So it’s definitely used in a lot of places.
3
u/christian_iphone Aug 20 '21
Yeah Java rules for ever because I’m application based companies it is mandatory and for product based also springboot is quite essential.
3
u/nutrecht Aug 21 '21
Almost any large site you use has a lot of programming in the background that handles 'stuff', storing and retrieving information mostly. This is called the 'back-end'. In large commercial applications these are often a lot of different applications or servicies working together.
In this type of enterprise environments, Java is by far the biggest player. If you use any large web application I'd say that probably at least 50% of what you use is using Java somewhere in the back-end. Your bank, Amazon, Google, Facebook, Netflix. They all use Java. Some use a bit, some are mostly based on Java (Amazon and Netflix for example).
6
u/its_PlZZA_time Aug 20 '21 edited Aug 20 '21
I don't necessarily know the "best" but just to give some examples:
A lot of data applications run I'm the JVM and are written in Java or Scala. Postgres Cassandra, Spark, and Hadoop for example.
Android apps (though I'm less familiar with this)
A lot of server side development is done in JVM languages. Spotify I know uses Java for all their external facing production apps (although not all of the clients, obviously)
3
u/an_actual_human Aug 20 '21
Postgres is written in C.
1
u/its_PlZZA_time Aug 20 '21 edited Aug 20 '21
Oh damn, you right. I was thinking about a podcast episode a while back about a product which was basically re-write of Cassandra in C and somehow the two got switched in my head.
2
2
u/wnaderinggummiofdoom Aug 29 '21
If you're done learning Java core, start learning the full Java ecosystem. As far as a project, why not make a webapp that allows users to register, login and view their skill tree (just use dungeons and developers skill tree).
Focus mostly on picking a build tool (maven is most popular from what I've seen) structuring your project according to that build tool and getting everything working. What you learn and what you make are only limited by how many books you read while doing this.
3
52
u/Squiggyline91 Aug 20 '21
I'd argue just about every enterprise environment is utilizing java for web services.