Java Bean mapper performance tests

As a follow up to my tests with the Introspector from the Java API, I did some more testing with the following Java Bean to Java Bean mappers:

Furthermore I used my own implementation and an implementation that’s hardcoded by hand.

The Eclipse project with the sample code for this post can be downloaded as tar.gz or zip or can be viewed online here.

Continue reading →

Performance tests for introspection of JavaBeans

Java has the Introspector class that either uses the Reflection API or explicit information about a bean stored in a BeanInfo object. This class provides a standard way to access the properties of JavaBeans and comes in handy if you’d like to copy properties from one bean to another in a generic way.

Continue reading →

Comparison between Guice, PicoContainer and Spring

For quite some time it was obligatory to use Spring in a Java project; it became a defacto standard. Once you’re familiar with dependency injection you don’t want to code without it. One alternative to Spring was and still is PicoContainer. But then Guice came along: Googles lightweight dependency injection framework. I investigated it at the time it was released and now I wrote a simple comparison between Guice, PicoContainer and Spring because I’d like to integrate one framework into a project I’m working on.

If you’d like to read and watch something about Guice or Google check out the following links:

During this comparison I’ll try to focus on DI only. To conclude that, say, Guice or PicoContainer is better than Spring, would be too general to be useful, since Spring is a lot more than just a DI framework.

Continue reading →

Performance comparison between Groovy and Java

I really like Groovy: the syntax is similar to Java and will be standardized. This looks promising and like a good investment into the future so I thought about integrating it into a project I’m working on. But first I wanted to compare code written in Java to the equivalent in Groovy and check the performance.

Continue reading →