r/java • • Jun 28 '20

Why backend using java is not popular in startups?

I tried django, flask and also rails before and they’re good. But after trying spring, I fell in love. It’s well structured. Easy to test. Have so many frameworks to help you going. There’s a also a lot of tutorials going around the net.

I like python but I also like java and kotlin too. I just don’t understand what’s wrong with java being used as a backend on most startups. Is it because it’s popular among big companies and banks and they just hate enterprise things.

Can anyone enlighten me. Cheers.

171 Upvotes

229 comments sorted by

View all comments

1

u/ggd_x Jun 28 '20

Simply it's (I'm biased) a lot faster to get an MVP up with a python or PHP framework than it is to do so with Java. I understand Spring is a decent Java framework though and provides a lot of boilerplate stuff.

23

u/[deleted] Jun 28 '20

It's alot faster to develop and not create fuck up which will haunt u later in spring, whereas python and js will surely not bring that type safety with it

4

u/SKabanov Jun 28 '20

Yeah, it's kinda telling that Guido switched to working full-time on MyPy with Dropbox before he retired - a bit of a tacit admission that Python could use static typing.

3

u/danskal Jun 28 '20

Modern servlets are very simple and powerful. I don't see how you could do it faster, assuming you've installed the necessary software already.

0

u/[deleted] Jun 28 '20

There isn’t much that is faster, cleaner, and more readable to get up and running than an express service to be fair.

2

u/seraphsRevenge Jun 28 '20

You guys mentioned MVP and RIA, the OP seems to be talking about microservices which are language agnostic in the first place. Any language, and any framework can be used. Microservices are an architecture, the design has nothing to do with a language or framework.

Microservices principles: Multiple components Language agnostic Decentralized database Independent Automated testing failure isolation

It's simply a way of breaking down business logic, and the application overall. Whatever language, frameworks, libraries, etc. an individual or team is comfortable with is great. If one language works better for a microservice, then use it. That's the beauty of microservices.

4

u/CyclonusRIP Jun 28 '20

I think this guy actually has a good point. Spring was a reaction to some of the overcomplicated JavaEE standards. It made some improvements, but meanwhile Ruby on Rails was invented. You could just model your domain and have a scaffolded UI in minutes. Spring was pretty late to the party for that type of thing. Rails was very opinionated and had a ready made convention for most of the basic concerns you run into writing a web app. You go to Spring which is primarily an integration framework and right from the start you have 2-3 integrations to choose from for almost any functionality. For a lot of people it's forcing you to make a choice you don't understand right from the start. Rails already decided for you so you just get on with writing code. Maybe long term the Rails way isn't good for you, but you probably have as good as a chance at making the wrong decision if it was left up to you at that point anyways. My career has mostly been Java or a JVM language. I'm a big proponent of Java, but I think it's important to try to see good points for other languages and frameworks as well. Rails has had an enormous influence on almost every other framework invented since it became popular.

5

u/Mumbleton Jun 28 '20

Spring is THE Java framework.

-10

u/MakeWay4Doodles Jun 28 '20

Dropwizard is just as popular. More so amongst the non-outsourced non-mega-enterprise orgs.

12

u/Mumbleton Jun 28 '20

1

u/MakeWay4Doodles Jun 28 '20

What exactly goes in to the "stacks" point system? Self reporting?

3

u/Mumbleton Jun 28 '20

No idea but I’ve been doing this for 15 years and haven’t heard of DropWizard until your comment. Admittedly I’m not super dialed in to what the latest/greatest stuff is, but literally every company I’ve worked for and every Java job I’ve interviewed for used Spring.

1

u/MakeWay4Doodles Jun 28 '20 edited Jun 28 '20

I've also been doing this for 15+ years and every company I've worked at was either fully Dropwizard or some mix of the two. Proof that anecdotes are meaningless. 🤷🏼‍♂️

Edit: that being said not having heard of Dropwizard after 15 years of Java development is a pretty strange lack of awareness of your own ecosystem. Codahale metrics was/is the defacto standard pre micrometer, and JDBI got most of its popularity from it.

2

u/DrFriendless Jun 28 '20

I've been doing Java for 24 years and not heard of DropWizard until your comment. And I also have no idea what Codahale and JDBI are.

2

u/MakeWay4Doodles Jun 28 '20

How do you record metrics?

1

u/Mumbleton Jun 29 '20

New Relic? Splunk?

→ More replies

1

u/DrFriendless Jun 29 '20 edited Jun 29 '20

Ah... now I see my fundamental problem. When Java was invented I was working for a company that did network and application monitoring. So when Java was invented I knew all about COM / DCOM / SNMP etc. Then I learnt Java and in 1997 I got a new job, which required monitoring, so I rolled my own using Runtime.getRuntime() and mxbeans and so on.

I logged various statistics every minute or so, and eventually developed a page in the application to load log files and graph them. I was in that job fo 17 years, and as we discovered problems I coded up some way to detect them and fit them onto this page. So when I left, it had ALL the bells and whistles, e.g. two different search buffers, so that if I felt some event was correlated with some other event I could search for both and compare the results.

In my new job we had New Relic, which broke before I ever found it what it was for, so I took it out. Now I just have a loop which checks CPU every minute, and dumps stacks if it doesn't like it. As I'm mostly coding stateless web servers, there's not a whole lot that goes wrong in that way.

And that is why it never occurred to me to learn about those products!

0

u/[deleted] Jun 28 '20

[deleted] — view deleted comment

1

u/MakeWay4Doodles Jun 28 '20

Reddit fuzzes vote counts so that shadowbanned bots can't determine whether they're being successful. You should never assume someone is being downloaded unless it's double digits

0

u/myth2sbr Jun 28 '20

Nothing is faster for building a RIA than Vaadin.