Creating a Maven archetype (Struts2/Spring based web application)

February 18, 2009

An archetype in Maven is a template (predefined package structure, resources, configuration files, source files, etc…) which can be used to start the development of a new application.

Amongst various benefits I like the possibility to provide the developers with a set of resources and classes (implementations!) which are going to be needed in the new project. This speeds up the project-setup time and facilitates the adoption of best practises employed within the team.

BTW Maven has few out-of-the-box archetypes (quickstart application, web application, mojo plugin), plus you can find a variety of archetype for lots of frameworks/technology (Struts2, Spring, GWT, etc…).

Here is a list of available archetypes (docs.codehaus.org).

Create a new archetype

The following sections go through the steps of creating a Maven archetype for a web application based on Struts2, Spring and Hibernate (and set of other utilities).

Read the rest of this entry »


Maven Tips & Tricks – Extension

June 11, 2008

Just added 3 more topics. Check it out: Maven Tips & Tricks.


Maven Tips & Tricks – Part 1

May 25, 2008

Check this out: Maven Tips & Tricks.

It is my collection of tips, notes, workarounds and good practices about using Maven 2 and some of its plug-ins. Hopefully a good way to start with the tool and get around some of the initial effort required by the configuration of the POM, plug-ins and various settings.

This is just a start (5 topics) but the goal is to add more samples and notes later, making it (possibly) a good reference.