Live data from Hacker News

Why and how I write Java

stevewedig.com

61–67 of 67 posts

Re: Why and how I write Java

#61
post #51

Earlier quoted context omitted.

>>I hired a junior developer a couple months ago ... his arrival meant our code base should be rewritten in a "more modern language". Needless to say that he didn't last very long. Aha, Let me tell you what the problem is here. This junior guy and most of his gang else where are starting companies with those 'Everything Else' languages. All these 20 hr/day working kids are working on all these cool shiny projects, bu…

You seem to enjoy generalizations and hyperbole quite a bit. First of all, such a small fraction of companies actually end up worth anything at all, so jumping to the conclusion that an arrogant prick who couldn't adopt to an unfamiliar development environment will go out and build a billion dollar company is incredibly unlikely. Maybe I'll be completely wrong, but the odds are undoubtedly in my favor. Second of all,…

>>We aren't going to rewrite our legacy Java codebase in Python or something else because there is absolutely no need for it

Neither would I, And if I were in your place I would keep Java running. And that was my whole point. Want to work on legacy stuff? Or the newer and better projects?

By the way, Python isn't that new these days either. Start up's I know of are going the Go, Clojure and Scala way.

>>when you're running the company, you have to consider things from a business perspective rather than a technical one.

Which is why for the new projects it makes sense to chose the latest tools which have little tech debt, which have fixed problems with older tools and will hang on for longer time.

>> people do nothing but sip the Java haterade without realizing what it is good for.

I don't debate that at all. But frankly speaking Java being good doesn't mean there are better things than that.

>>Honestly I couldn't care less- I'm not trying to change your way of thinking

Neither am I, I have seen first hand what happens when you stick to legacy tools. The jobs dry out, the projects you can work on move towards legacy end and lastly your career as a large suffers.

>>but in case some other aspiring dev is reading this, I'd strongly suggest to not be close-minded about powerful tools like Java that have mature ecosystems and an excellent community around them.

If a young dev is reading this, please treat tools as tools and have to special attachment to them. Learn to adapt and move on to newer things as and when necessary.

Re: Why and how I write Java

#62
post #17

Earlier quoted context omitted.

I took this out because it was unclear. I meant scripting in the sense that Python and Ruby are called "scripting languages". One possible policy is to use Java for your application, and something like Python to write scripts for stuff like devops or whatever else "scripting" is. Instead of this, I prefer use one language as much as possible, currently Java.

I rolled my own java scripting tool. Its pretty easy to do, but I think that most folks do this with Groovy now.

Quick & dirty scripts for testing and such where speed doesn't matter is Groovy's strength. Its managers at VMware are trying to use the Groovy distro as a delivery channel to sneak other unrelated software into businesses, such as a static compiler and type checker which were written by one person only and have virtually no commercial use. There's many other higher quality languages out there for JVM static compilation, e.g. Java 8, Scala, Ceylon, Kotlin, each of which have far larger teams working on them.

Re: Why and how I write Java

#63

I think one thing that this post touches on is the effectiveness of Java as a programming language for large projects. Although personally I've moved on to Python since it greatly simplifies web-related tasks, a lot of our legacy projects are in Java and I still hear plenty of people sipping the Java haterade. So I thought I'd share some of the most common things I hear. Only my grandpa writes in Java anymore. I hire…

There are plenty of reasons not to have GC run on a server. Let's say you're running an FPS client-server architecture. Good luck writing that in Java. Latency matters.

Absolutely, I wouldn't really use Java for any client-server architecture, mainly because there are other tools that are way better. And yes, latency does factor in that decision as well.

One thing to note is that even if you did have a large-scale Java deployment, you have to think about how much the GC is costing you. Depending on what percentage of time the JVM spends in GC, that can translate to millions of dollars worth of computing time. This is a very real problem that arises when businesses try to use Hadoop for creating solutions at scale.

Re: Why and how I write Java

#64

Earlier quoted context omitted.

GWT may not be fashionable, but the compiler and other development tools are very advanced, and big Google products use it. So I'd think twice about bashing it.

What big products? The only one that I know of is blogger. Google also recently stopped supporting it and made it an independent open source project, which is a mark against it. I'm not sure where you got the idea that the compiler was advanced - what it does is amazing but incredibly slow. The development tools were fine in 2008 but they're showing their age now... the browser plugin only runs in Chrome, Firefox and…

Adwords administration, Adsense administration, Google Play administration, Google Groups, probably several others I don't remember right now. Amazon AWS admin interface is GWT and so are a lot of other big projects you know of.

It is an extremely powerful tool, with some big caveats too, as you mentioned.

Re: Why and how I write Java

#65
post #41

A little surprised Spring is not mentioned. Composition in Java is a nightmare without Spring, and you can do some really interesting things in configuration that would take you days of writing initialization code in very little time. If not for Spring, I'm not sure I would want to construct things in Java at all.

Because he doesn't use Spring, he uses GWT.

There is no overlap between the two, you can use Spring with GWT as easily as with any other project. You probably mean Spring MVC.

Re: Why and how I write Java

#66
post #60
post #57

Earlier quoted context omitted.

>> But it will mostly legacy code, and by and large unimportant projects which no one really cares about in any company Tell that to Google and Amazon.

Even in those companies. The legacy systems are in place only because the cause of replacing them is prohibitively high. I've worked in Indian IT companies where most of the outsourced projects are legacy system which the contracting company doesn't want its own people to maintain anymore. Its a bad situation to be in. One company I know of had something like 40000 COBOL programmers, who work on projects from big ban…

Kamaal, do you work for either Amazon or Google? Neither company considers Java a legacy language. Do you know Google also builds applications in C++? Would you consider that legacy? How about C? How about C#? Simply because it's old does not mean it's outdated. Java is hampered more because of how inflexible the people who define are than any particular feature.

Re: Why and how I write Java

#67
post #60

Earlier quoted context omitted.

Even in those companies. The legacy systems are in place only because the cause of replacing them is prohibitively high. I've worked in Indian IT companies where most of the outsourced projects are legacy system which the contracting company doesn't want its own people to maintain anymore. Its a bad situation to be in. One company I know of had something like 40000 COBOL programmers, who work on projects from big ban…

Kamaal, do you work for either Amazon or Google? Neither company considers Java a legacy language. Do you know Google also builds applications in C++? Would you consider that legacy? How about C? How about C#? Simply because it's old does not mean it's outdated. Java is hampered more because of how inflexible the people who define are than any particular feature.

The difference is C, C++, and C# have continued to progress as languages (for better or worse). Java the language is stagnating. Language feature wise it's several years behind C# and C++. Meanwhile Scala is scooping up what Java is lacking.
Post reply on HN