views:

148

answers:

5

Guys,

Long time Java developer here, but I've spent more time working with Ruby over the past 3 years or so as far as web applications go. I really have enjoyed it, but there are concerns I've uncovered that I won't cover here.

Now that I've found the Play! framework, I'm thrilled about the prospect of having a Rails-like experience with Java's speed and reliability. Aside from what Play! provides out of the box, I'm looking for recommendations on "can't miss" libraries and tools for the Java developer used to pragmatic, dynamic experiences. I've found Project Lombok, which looks like a very intriguing way to eliminate a lot of the boiler plate, unnecessary Java noise. What else should I know about? I know Google has released quite a few libraries over the past three years that I've heard mentioned on the Java Posse, but I can't recall exactly what they are. I'm sure I've missed others in my absence.

So, what makes up your essential Java toolbox these days?

Thanks for your answers!

+4  A: 

I'd say Guava is a MUST. You also might want to check out guice by google.

If you are interested in multi-threaded programming, then java.util.concurrent is a must...

Enno Shioji
That's definitely one of the libraries I was trying to remember. Thanks!
jbwiv
+2  A: 

There's been a lot going on with languages that run on the Java Virtual Machine, leverage the Java libraries, and interoperate with Java, but that are more expressive. Take a look at JRuby (which runs Rails), Groovy (and the Rails-like Grails), Clojure, Jython (a Python implementation), and even Javascript (see the Rhino interpreter, written in Java).

Particularly interesting is Scala, very elegant fusion of object-oriented programming and functional programming. Scala's nearly as fast as Java, has the best interoperability with Java, and is very expressive. Scala programs can be much shorter than Java programs. The Lift Framework is comparable to Rails in the Scala world.

Jim Ferrans
I'm very familiar with JRuby and Groovy. I like both, but Grails is simply a Groovy veneer over a complex set of Java projects, and debugging problems can be a nightmare. I guess what I'm asking for is java-specific libraries and tools. I've done the dynamic language thing for some time...but I'm ready to at least experiment with static typing and java again ;-)
jbwiv
(Scala is statically typed but uses type inference to make it feel something like a dynamic language.)
Jim Ferrans
On the library front, take a look at Google Collections (part of the Guava project @Zwei pointed to). I've been really happy with iBatis (a persistence manager) and Restlet (a framework for supporting RESTful web applications and web services). I'm also using Google's Jackson JSON library.
Jim Ferrans
+1  A: 

I always have one eye on commons-lang . A lot of nasty stuff was encapsulated in the classes. It helps for example to write equals and hashcode. I'm comparison to projectlombok it does it at runtime via reflection, but with the possibility to exclude special attributes.

For concurrency you could have a look on Akka, which is available for Scala and Java. I never can tested it, but I heard a session on the JAX about it and it seems to be good.

niels
A: 

To make my non-web software "open" i always add (embeeded) Jetty and recently RESTEasy. Makes a "restfull" API a child's play.

PeterMmm
+1  A: 

Today, I found lambdaj which gives you a lot of nice groovy-like possibilities. I haven't any experience with it, but I think it's worth to have a closer look on it.

niels