Monday, September 5, 2011

lombok-maven-plugin 0.10.0.2 is available

The clever team behind Project Lombok released a new version recently: 0.10.0. This new version includes some breaking changes to the internals rendering my maven-lombok-plugin unable to adapt. But do not fret, because lombok-maven-plugin has been born to take its place.

The new plugin can take advantage of Lombok 0.10.0 which includes several bug fixes and new features such as:

  1. Support for Java 6 and Java 7
  2. A new val keyword (like Scala)
  3. Support for Lazy Getters
  4. Convenient annotations for a Logger
  5. A new annotation supporting easy delegation
  6. Delombok will remove lombok annotations
Also, the new plugin introduces a testDelombok goal for those who are interested in leveraging lombok for test code.

Finally, I discovered that the project was not Mac friendly, mostly due to the fact that Lombok requires tools.jar and that does not exist on a Mac (it is combined with classes.jar which is included automatically). I wanted to come up with a strategy where projects would work for Windows, Macs, and Linux, and so the Introduction shows how a Maven Profile can be added to achieve platform portability.