Perez Ronen wrote:
Guys, I am trying to push Maven in my organization, so I am facing the reality
of existing mega projects with mega chaos and the resistance of some zealous
ant users. Do you have an operative suggestions?
Unfortunately there is not a best practices guide.
I can give you a few pointers based on my experience running a small
development group and listening to the traffic here.
1) Post some more details about the type of project you are building and
a bit about the size and make up of your team. Any information that you
can give about your workflow and QC policies will help.
2) Try not to fight Maven or bend it to your will. Maven embodies some
unspoken set of best practices that are well supported and will make
your life better if you conform to its will. OTOH, there seem to be a
million plug-ins that encourages peole to do some odd things by making
it possible and even easy.
3) Do you have a repository set up? I am a bit fan of Nexus but there
are others that are frequently used. I wish that I had done that 2+
years ago. It adds a level of transapency and convenience to Maven that
really helps. I just have the free one but if you have a bigger team
with more complexity in your structure and workflow, you may get a lot
of benefit out of their professional version.
4) You should take a look at the build structure to see how the
project's dependencies are woven together. See how well the libraries
are organized so that libraries can be constructed and tested without
testing the whole mess.
Ant is a great tool but Maven makes your life easier once you get your
shit together.
There are some really smart people in the forum and you can probably get
some good advice and use cases to help move the ant-lovers to become
maven fanatics.
If you follow my #1 piece of advice I am sure you will get some help.
Ron
Ron
-----Original Message-----
From: Ron Wheeler [mailto:rwhee...@artifact-software.com]
Sent: ה 18 מרץ 2010 14:45
To: Maven Users List
Subject: Re: How to perform ordered tasks in Maven2 build
Another "Best Practice" example about how to structure a project into
Maven projects with libraries and dependencies to avoid the "Big Bang"
theory of deployment.
Ron
Perez Ronen wrote:
Hi,
I am trying to migrate a Java application built by Ant to Maven2. among other
the build perform the following operations:
1) Running a javadoc doclet to find annotated Java files to be externalize
later as web services
2) compile a small part of the code for step 3
3) run Axis java2wsdl on the compiled code from step 2
4) produce java code with wsdl2java on the wsdl files from step 3
5) compile the entire code
when trying to "mavenize" the process I can accomplish each task at a time but
fail to achieve them all in that order.
to demonstrate my pom and not load you with details I'll show the following
snippet:
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.6.1</version>
<executions>
<execution>
<id>aggregate</id>
<phase>generate-sources</phase>
<goals>
<goal>aggregate</goal>
</goals>
<configuration>...</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.1</version>
<executions>
<execution>
<id>compileWSfiles</id>
<goals>
<goal>compile</goal>
</goals>
<phase>generate-sources</phase>
<configuration>
<includes>
<!-- include 3 source files -->
</includes>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>axistools-maven-plugin</artifactId>
<version>1.3</version>
<dependencies>
<dependency>
<groupId>axis</groupId>
<artifactId>axis</artifactId>
<version>1.3</version>
</dependency>
</dependencies>
<executions>
<execution>
<id>java2wsdl</id>
<phase>generate-sources</phase>
<goals>
<goal>java2wsdl</goal>
</goals>
<configuration>...</configuration>
</execution>
<execution>
<id>wsdl2java</id>
<phase>generate-sources</phase>
<goals>
<goal>wsdl2java</goal>
</goals>
<configuration>...</configuration>
</execution>
</executions>
</plugin>
</plugins>
I pinned all of the build executions on the generate-sources phase and as far
as I know they should run in the order they are defined in the pom.
The main problem is that I have no control on the order of things and it is
obviously important here as every step output is the next step input.
any suggestions?
Thanks, Ronen.
________________________________
"This e-mail message may contain confidential, commercial or privileged information
that constitutes proprietary information of Comverse Technology or its subsidiaries. If
you are not the intended recipient of this message, you are hereby notified that any
review, use or distribution of this information is absolutely prohibited and we request
that you delete all copies and contact us by e-mailing to: secur...@comverse.com. Thank
You."
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org
“This e-mail message may contain confidential, commercial or privileged
information that constitutes proprietary information of Comverse Technology or
its subsidiaries. If you are not the intended recipient of this message, you
are hereby notified that any review, use or distribution of this information is
absolutely prohibited and we request that you delete all copies and contact us
by e-mailing to: secur...@comverse.com. Thank You.”
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org