Hi,

although it is possible to do this with maven I would rather like to see that the maven defaults are used - just because they are some kind of convention - and convention over configuration is one of the key features of maven. Anyway - I guess it is not a big deal to reuse the source folder for resources, so do it if feel you need it ;-)

cheers

Kai

--- Original Nachricht ---
Absender: Brandon Goodin
Datum: 08.08.2008 16:35
Hey All,

There was a private discussion regarding the project layout and maven
default conventions. I wanted to put the discussion out in front of
everyone else, purely to get feedback and thoughts.

At the moment the src directory contains source *and* resources. Maven
has been configured to recognize the src/main/java as the resources
and java directory. The reason for this is that it can get tedious to
move between the java and resources directory rather than just edit a
resource in the same package as the java class.

The approach of using the java directory as a dual purpose directory
is a departure from Maven's default directory structure. The concern
of departing from that structure is that it may cause additional
difficulties as we make heavier use of maven for coverage and
reporting. If we experience difficulties in the future with Maven
(because we all know it can be temperamental) it may be that we start
having to separate all the resource files out of the java directory in
order to eliminate it as a cause.

So in summary...

Current reasons for dual purpose java directory:
* iBATIS 3 will make use of convention configuration and the visual
proximity of resources to java is more visually correct
* All around less directory clutter


Concerns and counterpoints to making the java directory dual purpose:
* Most IDEs can merge the resource and java directories in a package view.
* We run the risk of avoiding potential maven headaches with plugins
that don't handle the combined java/resources approach.


In the end the question would be... Is it better to have coding
convenience or follow the maven default approach of separating java
and resource? Any experiences and comments are welcome.

Brandon


Reply via email to