Hacker News new | ask | show | jobs
by mindcrime 2743 days ago
Groovy.

Because it's "java like" enough that all of my years of experience using Java still pay dividends, but yet it knocks off most of the warts Java has (writing getters and setters, for example), while adding cool stuff like dynamic typing, closures, currying, map literals, string interpolation, tons of handy convenience methods, etc.

1 comments

> adding cool stuff like dynamic typing, closures [to Java]

Both dynamic-style inferred typing and closure-like lambdas have been added to Java since Apache Groovy was first released. Groovy's business case has become less compelling as a result.

Groovy's business case has become less compelling as a result.

By a small margin, yes. Personally, I still find Groovy far more compelling than plain Java, especially when I'm using Grails for "web stuff". For pure backend REST services, I do sometimes go with plain Java and Spring Boot. As the old saying goes "use the right tool for the job". Hell, I'd use COBOL if there was a compelling reason. :-)

I thought that too at first, but actually trying to use lambdas in Java still ends up a lot more verbose and cumbersome than the kind of fluid APIs you can do with Groovy.