7 ms·
Seriously not trolling, but can someone please explain why java would be a great choice of language for a modern project? What's the sell, these days for java?
by forgottenacc57 9y ago
Seriously not trolling, but can someone please explain why java would be a great choice of language for a modern project?
What's the sell, these days for java?
- NikolaeVarius 9y agoThere is nothing to sell. Its a modern language that many people know and are experienced in and many extremely large scale and modern projects are written in it. Why does anyone need to sell anything? So we can all go ahead and spend 5 years getting good at clojure and haskell?
- buahahaha 9y agoAs not a java guy: very good concurrency support, the memory consumption isn't really a big deal anymore and the tooling connected to the jvm for introspection are very valuable and relatively easy to set up, strong user base of programmers relatively speaking, the language updates have kept it relatively fresh and useable - much cleaner than what you remember for 5-8 years ago - and it runs easily on many systems. It has good inertia: once some of your projects are already in java, it's easy to just add onto that. It has solved many of the day-to-day problems that younger languages haven't reached yet (distributed packaging, metrics). And everything supports it.
- jhall1468 9y agoEnterprise support. But the reality is, most Java shops continue to use it because that's what all of their engineers know. There's literally nothing that Java (the language) provides me that other languages don't (and better). If I were to start a project today, I'd pick from a more modern list of language (Go, Python, Rust, C#). Java would never make the list.
- kodfodrasz 9y agoJava is also nice. I like it very much. (I'm a C# guy.) Java is pretty modern, has quirks, but you can be pretty productive, not a particularly bad language. Helps you get stuff done. Awesome tools, pretty good concurency support. It is very hish performance. It is a proven tool, just don't buy into the IBM/RedHat enterprise stuff. There are nice microframeworks available. Java is a good choice to start a project in.
- jhall1468 9y agoIt's not a bad language, it's just alternatives are vastly better for a typical startup. Java is the language that's "Good at everything", while these days we have languages that are "Great at some things", and often, whatever the use case, there's simply a better language for it. What makes Java powerful is that it's good at everything. That's incredibly valuable for Amazon and Google, because they have an insane amount of code. So whether they need concurrency, or tooling, or whatever they can throw any 4-5 engineers at the problem and they'll be able to get it done. For a startup, they aren't going to need the greatest General Purpose language ever made. They generally have specific problems. And there are simply better languages out there for almost all of them.
- pvg 9y agoWhat are the specific problems that are so radically different than the specific problems somewhat bigger companies might have? What does "For a startup, they aren't going to need the greatest General Purpose language ever made" mean?
- jhall1468 9y agoThe biggest problems big companies have is that they need to do everything. If I have a companies with 2000 engineers and I have projects in ML, Rest Servers, Cloud systems, etc, it makes vastly more sense to rely on one language to do everything, because it allows me to shift engineers from one place to another without them having to learn a new language. If I'm a startup, I generally have ONE thing that I need to excel at. If that's computer vision, why would I use Java when C++ (and arguably Python/OpenCV) is decidedly better at computer vision? If I need a simple REST service for my particular project, why in the world would I use Java over Python, Ruby or Go? The value of Java is that it does everything well, but the ecosystem is enormous. It's overkill for most projects, unless you happen to have projects that scale across multiple domains that Java does well. I find it odd that I'm getting so much push back here. There's a massive amount of cognitive overhead in utilizing Java. There's also a huge cost (both cognitive and entry) in using of Java. (The difference between a Java programmer and a generalist? How much the latter has to learn to catch up.)
- SomeStupidPoint 9y agoBuying in to Java is also buying in to the JVM -- you can interop easily with languages like Clojure, Kotlin, or Scala, which lets you write some of your code in sexy languages while other parts are holding down the fort using boring, but battle tested ecosystem. (C# and F# are a similar combo.) There are also some high profile pieces of technology written in Java, so if you want to leverage them, having JVM expertise is a bonus. You may even get better bindings for JVM languages than others and since many are open source, having Java expertise allows you to work on them. I find it a little odd you'd buy in to the CLR family (C#, F#, etc), but say the JVM family has nothing to offer. They're not really substantially different in my experience -- both are sort of staid enterprise-y ecosystems. (But maybe I'm missing something really cool in CLR land besides good MS product support -- please let me know! It's one of my language blindspots.)
- jhall1468 9y ago> I find it a little odd you'd buy in to the CLR family (C#, F#, etc), but say the JVM family has nothing to offer. I just find C# to be a better language. It has its youth to thank for that. I have no issues with JVM. Hell, if I were to start a project today Kotlin and Scala would also be very real possibilities. They are both amazing languages. C# probably shouldn't have made my list, but I threw it in there to cover OOP where the other languages were decidedly not. At the end of the day, language choices for a start up largely reflect it's goals. If I want to do statistical modeling, I'm going to use R. For ML, probably Python. For a systems program, likely Rust. The bottom line with Java is that it can do any of those things. But the languages I mentioned do their specific job better. And that's the thing with a startup. You don't need a great general purpose language, you need whatever language suits your niche. But at Amazon/Google scale, Java is an absolute beast, largely because it can do everything.
- deleted 9y ago[deleted]
- klodolph 9y agoAll the libraries you need. Fantastic runtime environment. Easy to hire programmers and admins who work with it. It's $HOT_NEW_THING which really needs to be sold.
- songshu 9y agoExactly. You're not choosing a language, you're choosing a platform. If people chose "languages" then yes, Java would be a hard sell, but so would C++ and much of the rest of the top ten.
- soulnothing 9y agoOkay I buy this, and say the thing about python. It's more the ecosystem than the language. But java has so many great languages on the JVM. That inter op flawlessly with it. Kotlin is my favorite, and allows both java and kotlin files in the same project. The language is palpable. But I feel that there are higher level features, that can ease development and improve readability. Yes, yes the IDE can generate boiler plate. But that shouldn't be necessary.
- amyjess 9y agoI love Python to death, and it's my favorite language, but packaging and deploying Python apps have always been the ecosystem's Achilles heel. It's not hard to send a Java app to a Windows user and expect them to be able to run it, which is more than I can say for Python. And Java also has Maven, which is by far the best dependency management system I've used. It's extensible too... aside from managing dependencies, you can also have Maven perform code generation (which is wonderful if you're working with Avro) and other things (such as handling OSGi bundle metadata).
- soulnothing 9y agoI'm mostly a python dev. But yes deployment is such a pain.
- joncampbelldev 9y ago
- maxxxxx 9y agoI don't use Java but from what I know it's a very mature environment with excellent tooling and library support. I am not convinced that the same people who mess up Java code will do any better with other languages.
- srdev 9y agoGreat performance, a massive community, top tier support by partners and vendors, deep talent pool, and a huge ecosystem of libraries and products. Nothing else even comes close. People have a tendency to trash talk it for being verbose, but writing the code is a vanishingly small portion of the engineering effort, and if you're hand wringing about whether it's fun to write then you're optimizing for the wrong things.
- maxlybbert 9y ago> if you're hand wringing about whether it's fun to write then you're optimizing for the wrong things It's hard to imagine what kind of career that attitude would lead to. I very much worry about whether things are fun to write. And I've been lucky that, so far, I've had jobs that were very fun. Not necessarily easy, but fun.
- srdev 9y agoI guess it depends on how much writing the actual code factors into your enjoyment. Most people I know enjoy building systems. Working with a boilerplate-heavy language is a minor annoyance in the grand scheme of things, and is balanced out by having a robust ecosystem to build their product in.
- bebop 9y agoIf you have not recently looked at what is happening within the Spring Framework, I would highly suggest taking a look. There are some really great tools that are baked in. Also if you are planning on writing containerized microservices, Spring offers a really nice environment to do that. And if you do not want to use Java the language, there is always Kotlin (and Scala).
- api 9y agoPros: Fast, stable, mature, excellent tooling, big ecosystem, and easy to hire programmers. Cons: Oracle's shadow of semi-legitimate FUD, higher memory consumption, ecosystem is rife with over-engineering and the language seems to almost encourage it.
- matwood 9y agoJava 8 is great. Java 8 + Spring boot + JOOQ is a complete, easy to setup web service backend. It has great tooling, is very fast, and has an enormous amount of libraries available. I actually question why anyone would use Node except in a few cases (like backend for front end), but maybe I'm just old school :)
- raverbashing 9y agoHow many XML files have to be configured for this "easy to setup" backend? Node is "simple" but today you need 3 package managers to install the dozens of small libraries needed for even a simple project Really. When I found out express.js needs an extra library to read POST data I was stumped
- asdf1234 9y ago> How many XML files have to be configured for this "easy to setup" backend? None.
- amyjess 9y agoHave a look at Spark: http://sparkjava.com/ http://sparkjava.com/ It's a Flask clone for Java. No XML configuration needed.
- sabareesh 9y agoZero xml files.
- deleted 9y ago[deleted]
- matwood 9y ago> How many XML files have to be configured for this "easy to setup" backend? As the others mentioned, Spring has not required XML config files in a long time. Spring boot requires nearly zero configuration, although it's a good idea to move out environment specific configurations out of the app. Speaking of, out of the box Spring works with yaml, properties, environment vars, command line vars, and the list goes on. It really is a nice environment to work in, and if you don't like Java there is Kotlin which has worked fine within the stack IME. So many people only remember Java 5 and Spring where beans had to be wired up through XML configs.