wood burning stoves
The moose likes Other Open Source Projects and the fly likes Maven and CruiseControl Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Other Open Source Projects
Bookmark "Maven and CruiseControl" Watch "Maven and CruiseControl" New topic

Maven and CruiseControl

Todd Farmer
Ranch Hand

Joined: May 28, 2004
Posts: 59

I am trying to get up and running with CruiseControl, using Maven for builds. I had an Ant wrapper that CruiseControl would call to import the source code from my file system (single-developer environment, but in process of implementing Subversion). I then have to call Maven to generate the build. I tried including both an <ANT> and <MAVEN> process in the <SCHEDULE> for CC, but it appears that CC starts on the MAVEN build process before the ANT file prep process completes.

I'm not too keen on changing my project.xml or maven.xml files to include file prep steps that are specific to my machine. I think this leaves me with 2 alternatives:

1. Convert the Ant script to a Maven process to prep the file system and spawn a new instance of Maven for the build process itself. This would require Maven to be able to create a new Maven instance.

2. Call the Maven build process directly from the Ant script. This would require an Ant task to call Maven.

I don't know if either of these are feasible. Are there any suggections or solutions from people who have integrated CruiseControl and Maven? If I'm on the wrong path, please let me know.
kri shan
Ranch Hand

Joined: Apr 08, 2004
Posts: 1428
Why are u using two different build tools Ant & Maven ?
Todd Farmer
Ranch Hand

Joined: May 28, 2004
Posts: 59
I would love to be using just Maven. I'm only using Ant because I don't know how to do all that I need to do through Maven. Here's where I'm falling short:

I want to have a wrapper for Cruise Control to call. I don't want to call the build process directly, because I have to prep the build environment, which is a step that is specific to CC builds. I want to use the same Maven POM to generate test builds directly from my development environment as well.

With Ant and CC, it's my understanding that the best solution is to provide a wrapper Ant script which CC calls. This wrapper preps the environment and delegates to the main Ant build script. In other words, Ant calls Ant. I would love to do the same thing with Maven; either have Maven prep the environment and then call the Maven build process, or have Ant call Maven.

Perhaps I'm going about it the wrong way and really need to have a custom preGoal in Maven or something like that; I don't know.
I agree. Here's the link: http://aspose.com/file-tools
subject: Maven and CruiseControl
It's not a secret anymore!