Saturday, 21 November 2009

Reading Apache Maven 2 Effective Implementation

Thanks to Amit Sharma (of Packt Publishing), I recently got a copy of Apache Maven 2 Effective Implementation authored by Brett Porter and Maria Odea Ching.

The book has proven to be an interesting read so far (even for an advanced maven user), covering a lot of important (and sometimes little known) plugins. Its best practices chapter along with the real-life advices/tips that are found throughout the book are a must read. On the other hand, I would really have liked to see a chapter or appendix covering maven support in IDEs + I must admit don't have much of respect for Archiva (that's based on a few weeks interaction i had with it 3 years ago - perhaps things have improved?) which is covered in detail in the book, along with Continuum.

Anyway, expect a complete review soon.

Technorati Tags:

Posted by default at 12:11 PM in java/

Monday, 5 October 2009

Maven and slow dependencies report

If the dependencies report takes too long to finish, it could be due to maven trying to determine (and generate a report of) which repository contains which artifact... and the network and/or repos being slow or unreachable.

In any case, here's how you can short-circuit that process:

mvn -Ddependency.locations.enabled=false site

Technorati Tags:

Posted by default at 2:41 PM in java/

Tuesday, 17 March 2009

Maven Presentation

On Feb 14 (yep, that was the Valentine's day), i did a Maven presentation for out local Java User Group, and it looks like it was very well received (which is great cause i was terribly nervous at the begining ).
Here are the contents (embedded from slideshare):

Technorati Tags:

Posted by default at 8:45 PM in java/

Sunday, 15 February 2009

Java time @ 1234567890 via groovy console

Java time is 1234567890

Technorati Tags:

Posted by default at 6:17 AM in java/

Monday, 2 February 2009

Tapestry 5.0 refcard featured as dzone.com

refcardz.dzone.com just added a brand new refcard on Tapestry 5.0 written by the creator of the framework, Howard Lewis Ship
The direct link for getting to the pdf is http://refcardz.dzone.com/refcardz/apache-tapestry-50?oid=hom7691, but i'm also including (via scribd.com) the card here, so enjoy!
Refcard #40- Apache Tapestry 5.0

Technorati Tags:

Posted by default at 6:26 PM in java/

Thursday, 13 November 2008

Quick maven tip for downloading sources of a specific dependency

This may come in handy. since on big projects with many dependencies it may take a while to download ALL sources. So, here is an example:
mvn dependency:sources -DincludeGroupIds=org.apache.tapestry

Technorati Tags:

Posted by default at 9:52 PM in java/

Thursday, 30 October 2008

Quick maven tip for deploying to remote FTP repository

First, you'll need to make sure the following jars exist in %MAVEN_HOME%/lib (i include the versions i currently have):
  • wagon-ftp (1.0-beta-2)
  • commons-net (1.4.1)
  • oro (2.0.8)
Then define a server (& its credentials) for the remote repo in your ~/.m2/settings.xml and finally issue something like:
mvn deploy:deploy-file -Dfile=mysql-source.jar -Dclassifier=sources
    -DpomFile=mysql-connector-java.pom -Durl=ftp://my.server.com/path/to/repository -DrepositoryId=my.server.id

Technorati Tags:

Posted by default at 8:06 AM in java/

Tuesday, 17 June 2008

Tapestry-4.1.6 maven archetype

There's an updated archetype for Tapestry-4.1.6-SNAPSHOT over at (the well known snapshot repo) http://people.apache.org/repo/m2-snapshot-repository

All the hard work was done by Ulrich Stärk, so big thanks to him

For the record, here's how to quickly generate a Tapestry project

mvn archetype:create -DarchetypeGroupId=org.apache.tapestry \
-DarchetypeArtifactId=tapestry-archetype \
-DarchetypeVersion=4.1.6-SNAPSHOT -DgroupId=org.example -DartifactId=myapp \
-DremoteRepositories=http://people.apache.org/repo/m2-snapshot-repository

Technorati Tags:

Posted by default at 3:38 PM in java/

Sunday, 11 May 2008

Tapestry for Nonbelievers

InfoQ has just released an article on Tapestry 5.
It's a well written article that manages to cover many of the new features introduced in Tapestry. It goes through:
  • Setting up a Tapestry application
  • Creating a page and a component
  • Using the awesome Grid component for easy display of your data
  • Using BeanEditForm for one-line pojo editing!!!
  • Ajax and ajax components
So, go ahead and read it.
And now, moving on to the exclusive content of this entry...

During my last trip to Germany (Emi and I were supposed to fly for Dubai, but we ended up in Frankfurt - that is another story) i got to meet the two authors of this article, Renat Zubairov and Igor Drobiazko.

So, here's a photo of the three of us drinking beer:

Technorati Tags:

Posted by default at 11:29 PM in java/

Sunday, 2 March 2008

Patching maven-surefire-plugin... yet again!

People have been using the 2.4-collab-SNAPSHOT of maven-surefire-plugin for a long time. The main reason for that was that the 'official' 2.4-SNAPSHOT was ... incompatible with the latest TestNG versions.
Thankfully, 2.4, 2.4.1 and 2.4.2 official versions have been recently released (Jan-Feb 2008) and TestNG support is back to normal. OR is it?
Well, according to SUREFIRE-463 (disclaimer: i filed and provided the patch for that) you're NOT able to run custom TestNG suite XML files, i.e. use the suiteXmlFiles configuration of the plugin, as described here.
So, if you too are bitten by that issue, go ahead and vote for it.

Technorati Tags:

Posted by default at 4:13 PM in java/