How can Maven be used to prepare a complex, multi-module JavaEE app for release
We have a complex JavaEE app with multiple wars, jars, ds.xml and config files, etc. In fact, there are over 80 different artifacts that make up our application. We use the maven-assembly-plugin to create a gzip file and untar it into a JBOSS instance to deploy and run. It's not pretty and it's a nightmare to actually do a release. We use Subversion, Maven 3, Nexus for repository management and Jenkins for build management. The following are the manual steps required for us to do a release: 1. Create a SNAPSHOT version of the changed modules and deploy to a test environment a. Create a SNAPSHOT branch in SVN b. Copy changed modules to the new branch from trunk c. Manually change the dependency versions from SNAPSHOT as needed in each individual POM d. Manually change the dependency versions in the assembly POM files (there are 5 sub assemblies and one main assembly to put them all together) e. Run mvn deploy on each new module to install SNAPSHOT versions to Nexus f.Run mvn install on each sub-assembly (I don't want to deploy the assemblies to Nexus) g. Run mvn package on the main assembly h. Copy and untar the main assembly on our QA JBOSS server/instance 2. Create a RELEASE version and deploy to production a. Merge the SNAPSHOT branch modules in SVN to trunk b. Repeat steps a-h, above, manually removing "-SNAPSHOT" from all the POM files I've tried to simplify a little by consolidating dependency management in the parent assembly, but it still requires that I modify each affected sub-assembly to use the correct parent version. Why not use the maven-release-plugin to eliminate the manual process, you might wonder? Great, then I have to modify each POMs scm element whenever I do a SNAPSHOT-to-RELEASE, and, unless I use module inheritance in my POMs at some point, the release plugin isn't going to recurse through all of the changed modules for me. I thought maven was supposed to relieve me of this manual configuration nightmare, but it seems to only have increased it. All of the documentation and Web-help I have seen discusses only simple multi-module systems, with maybe a war, an ejb and a domain jar, for example. That's child's play compared to what we have to deal with, and I'm just out of ideas. Maybe someone out there has faced a similar daunting task and can help. Thanks in advance.
[ANN] Webminifier Maven Plugin 1.0.0 Released
Hi, The Mojo team is pleased to announce the release of the Webminifier Maven Plugin version 1.0.0. This plugin provides JavaScript minification for Maven projects. It produces a minified version of JavaScript resources which can be used to construct a minified final artefact. It is designed to be flexible in the way it operates to allow for easy minified resource re-use across a project. Under the hood, Webminifier currently uses the YUI Compressor and Closure Compiler but has a layer of abstraction around these tools which allows for other tools to be used. http://mojo.codehaus.org/webminifier-maven-plugin/ We recommend the use of this plugin in the context of the forthcoming Javascript Maven Tools project (1). Alternatively to get this update, simply specify the version in your project's plugin configuration: org.codehaus.mojo webminifier-maven-plugin 1.0.0 The plugin is being heavily used by at least two large corporations. Enjoy, The Mojo team. Christopher Hunt (1) http://mojo.codehaus.org/javascript-maven-tools/
[ANN] JS Import Maven Plugin 1.0.0 Released
Hi, The Mojo team is pleased to announce the release of the JS Import Maven Plugin version 1.0.0. The JS Import Maven plugin essentially provides Maven dependency management support for JavaScript. Asynchronous Module Definitions (AMD)(1) are also supported. The import plugin supports js type artifacts and compressed bundles of web resources and will expand the latter into a project's target folder. Web resource bundles are denoted with a "www" classifier and a type of "zip". http://mojo.codehaus.org/js-import-maven-plugin/ We recommend the use of this plugin in the context of the forthcoming Javascript Maven Tools project (2). Alternatively to get this update, simply specify the version in your project's plugin configuration: org.codehaus.mojo js-import-maven-plugin 1.0.0 The plugin has been developed over the past year and is being heavily used by at least two large corporations. Enjoy, The Mojo team. Christopher Hunt (1) https://github.com/amdjs/amdjs-api/wiki/AMD (2) http://mojo.codehaus.org/javascript-maven-tools/
Committing non-POM files during release:prepare?
Maven 2.2, release plugin. During the preparationGoals, I'm modifying a .properties file that references the Maven project version. When the POM files get committed to Subversion after the preparationGoals have completed, I need this .properties file to get committed as well. Otherwise the release:perform step will fail. Is this possible? Thanks. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
RE: Trying to get multiple profiles to execute
You may want to read this article: http://maven.apache.org/guides/mini/guide-default-execution-ids.html > -Original Message- > From: Matt Walsh [mailto:mwa...@chartwelltechnology.com] > Sent: Monday, January 09, 2012 10:58 AM > To: Maven Users List > Subject: RE: Trying to get multiple profiles to execute > > Change one of your ids to "default-cli". > > > -Original Message- > > From: Artie Peshimam [mailto:apeshi...@gmail.com] > > Sent: Monday, January 09, 2012 10:43 AM > > To: Maven Users List > > Subject: Re: Trying to get multiple profiles to execute > > > > Hmm tried that and the plugin complained that it could not find the > > configs: > > [ERROR] Failed to execute goal > > com.dbdeploy:maven-dbdeploy-plugin:3.0M3:update (default-cli) on > > project > > Core2DB: The parameters 'driver' for goal > > com.dbdeploy:maven-dbdeploy-plugin:3.0M3:update are missing or > invalid > > -> > > [Help 1] > > > > > > http://maven.apache.org/POM/4.0.0"; > > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; > > xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 > > http://maven.apache.org/xsd/maven-4.0.0.xsd";> > > 4.0.0 > > com.cx > > Core2DB > > 1.0-SNAPSHOT > > > > > > > > true > > > > core2DB > > > > > > > > > > > > core2DB > > > > > > scripts > > > > com.mysql.jdbc.Driver > > mysql > > > > up_migrations.sql > > > > down_migrations.sql > > > > jdbc:mysql://localhost/cxc2 > > > > > > > > com.dbdeploy > > maven-dbdeploy- > plugin > > 3.0M3 > > > > > > > > mysql > > > > mysql-connector-java > > 5.1.6 > > > > > > > > > > > > > > > > activityDB > > > > true > > > > > > > > > > > > > > activityDB > > > > > > activityDBScripts > > > > com.mysql.jdbc.Driver > > mysql > > > > up_migrations.sql > > > > down_migrations.sql > > > > jdbc:mysql://localhost/activity > > > > > > > > com.dbdeploy > > maven-dbdeploy- > plugin > > 3.0M3 > > > > > > mysql > > > > mysql-connector-java > > 5.1.6 > > > > > > > > > > > > > > > > > > > > > > On Thu, Jan 5, 2012 at 2:57 PM, Matt Walsh > > wrote: > > > > > You might be getting conflicts in your configuration. Try moving > your > > > configurations inside the blocks. > > > > > > > -Original Message- > > > > From: Artie Peshimam [mailto:apeshi...@gmail.com] > > > > Sent: Thursday, January 05, 2012 11:25 AM > > > > To: users@maven.apache.org > > > > Subject: Trying to get multiple profiles to execute > > > > > > > > Hi All, > > > > > > > > Im trying to get multiple maven profiles to execute, but am > having > > no > > > > success. > > > > It's very straight forward. I have two profiles executing the > same > > > > plugin > > > > with a slight variation in configuration and each has a unique > > > > execution > > > > Id. When I try to execute maven, only one of the profiles > actually > > is > > > > run. > > > > > > > > Ideas? > > > > > > > > Here's my POM: > > > > > > > > > > > > http://maven.apache.org/POM/4.0.0"; > > > > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; > > > > xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 > > > > http://maven.apache.org/xsd/maven-4.0.0.xsd";> > > > > 4.0.0 > > > > com.cx > > > > Core2DB > > > > 1.0-SNAPSHOT > > > > > > > > > > > > > > > > true > > > > core2DB > > > > > > > > > > > > > > > > > > > > > > > > core2DB > > > > > > > > > > > > com.dbdeploy > > > > maven-dbdeploy-
RE: Trying to get multiple profiles to execute
Change one of your ids to "default-cli". > -Original Message- > From: Artie Peshimam [mailto:apeshi...@gmail.com] > Sent: Monday, January 09, 2012 10:43 AM > To: Maven Users List > Subject: Re: Trying to get multiple profiles to execute > > Hmm tried that and the plugin complained that it could not find the > configs: > [ERROR] Failed to execute goal > com.dbdeploy:maven-dbdeploy-plugin:3.0M3:update (default-cli) on > project > Core2DB: The parameters 'driver' for goal > com.dbdeploy:maven-dbdeploy-plugin:3.0M3:update are missing or invalid > -> > [Help 1] > > > http://maven.apache.org/POM/4.0.0"; > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; > xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 > http://maven.apache.org/xsd/maven-4.0.0.xsd";> > 4.0.0 > com.cx > Core2DB > 1.0-SNAPSHOT > > > > true > > core2DB > > > > > > core2DB > > > scripts > > com.mysql.jdbc.Driver > mysql > > up_migrations.sql > > down_migrations.sql > > jdbc:mysql://localhost/cxc2 > > > > com.dbdeploy > maven-dbdeploy-plugin > 3.0M3 > > > > mysql > > mysql-connector-java > 5.1.6 > > > > > > > > activityDB > > true > > > > > > > activityDB > > > activityDBScripts > > com.mysql.jdbc.Driver > mysql > > up_migrations.sql > > down_migrations.sql > > jdbc:mysql://localhost/activity > > > > com.dbdeploy > maven-dbdeploy-plugin > 3.0M3 > > > mysql > > mysql-connector-java > 5.1.6 > > > > > > > > > > > On Thu, Jan 5, 2012 at 2:57 PM, Matt Walsh > wrote: > > > You might be getting conflicts in your configuration. Try moving your > > configurations inside the blocks. > > > > > -Original Message- > > > From: Artie Peshimam [mailto:apeshi...@gmail.com] > > > Sent: Thursday, January 05, 2012 11:25 AM > > > To: users@maven.apache.org > > > Subject: Trying to get multiple profiles to execute > > > > > > Hi All, > > > > > > Im trying to get multiple maven profiles to execute, but am having > no > > > success. > > > It's very straight forward. I have two profiles executing the same > > > plugin > > > with a slight variation in configuration and each has a unique > > > execution > > > Id. When I try to execute maven, only one of the profiles actually > is > > > run. > > > > > > Ideas? > > > > > > Here's my POM: > > > > > > > > > http://maven.apache.org/POM/4.0.0"; > > > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; > > > xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 > > > http://maven.apache.org/xsd/maven-4.0.0.xsd";> > > > 4.0.0 > > > com.cx > > > Core2DB > > > 1.0-SNAPSHOT > > > > > > > > > > > > true > > > core2DB > > > > > > > > > > > > > > > > > > core2DB > > > > > > > > > com.dbdeploy > > > maven-dbdeploy- > plugin > > > 3.0M3 > > > > > > > scripts > > > com.mysql.jdbc.Driver > > > mysql > > > > up_migrations.sql > > > > > > down_migrations.sql > > > jdbc:mysql://localhost/cxc2 > > > > > > > > > > > > mysql > > > > > > mysql-connector-java > > > 5.1.6 > > > > > > > > > > > > > > >
Re: Mvn commands are stalling
On Jan 9, 2012, at 12:01 PM, Robert Scholte wrote: > Even though I'm not a newbie, I can see 2 potential problems with this > sentence: > 1. line 84, column 15 of what? It doesn't mention the file. Sure, it always > about the poms, but we're talking about unexperienced users here. > 2. build.plugins.plugin.version ? This doesn't look like xml, so maybe you're > not triggered to look inside the pom. And if you use a pom-editor, you may > have never seen the xml. Another observation I might try to append to Robert's list is how to separate the signal from the noise. My personal opinion is that Maven is pretty chatty, which is great for experienced users, but a bit overwhelming for some new users. One option would be to reduce verbosity, but that doesn't really serve experienced users well. Another option would be what Karaf has done and that is to use colorized logs. http://blog.uncommons.org/2006/04/09/colour-coded-console-logging-with-log4j/ covers the gist of it. The ANSI colorization characters are kind of ugly in terminals that aren't set up correctly, but it might help improve readability? Brian - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Trying to get multiple profiles to execute
Hmm tried that and the plugin complained that it could not find the configs: [ERROR] Failed to execute goal com.dbdeploy:maven-dbdeploy-plugin:3.0M3:update (default-cli) on project Core2DB: The parameters 'driver' for goal com.dbdeploy:maven-dbdeploy-plugin:3.0M3:update are missing or invalid -> [Help 1] http://maven.apache.org/POM/4.0.0"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd";> 4.0.0 com.cx Core2DB 1.0-SNAPSHOT true core2DB core2DB scripts com.mysql.jdbc.Driver mysql up_migrations.sql down_migrations.sql jdbc:mysql://localhost/cxc2 com.dbdeploy maven-dbdeploy-plugin 3.0M3 mysql mysql-connector-java 5.1.6 activityDB true activityDB activityDBScripts com.mysql.jdbc.Driver mysql up_migrations.sql down_migrations.sql jdbc:mysql://localhost/activity com.dbdeploy maven-dbdeploy-plugin 3.0M3 mysql mysql-connector-java 5.1.6 On Thu, Jan 5, 2012 at 2:57 PM, Matt Walsh wrote: > You might be getting conflicts in your configuration. Try moving your > configurations inside the blocks. > > > -Original Message- > > From: Artie Peshimam [mailto:apeshi...@gmail.com] > > Sent: Thursday, January 05, 2012 11:25 AM > > To: users@maven.apache.org > > Subject: Trying to get multiple profiles to execute > > > > Hi All, > > > > Im trying to get multiple maven profiles to execute, but am having no > > success. > > It's very straight forward. I have two profiles executing the same > > plugin > > with a slight variation in configuration and each has a unique > > execution > > Id. When I try to execute maven, only one of the profiles actually is > > run. > > > > Ideas? > > > > Here's my POM: > > > > > > http://maven.apache.org/POM/4.0.0"; > > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; > > xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 > > http://maven.apache.org/xsd/maven-4.0.0.xsd";> > > 4.0.0 > > com.cx > > Core2DB > > 1.0-SNAPSHOT > > > > > > > > true > > core2DB > > > > > > > > > > > > core2DB > > > > > > com.dbdeploy > > maven-dbdeploy-plugin > > 3.0M3 > > > > scripts > > com.mysql.jdbc.Driver > > mysql > > up_migrations.sql > > > > down_migrations.sql > > jdbc:mysql://localhost/cxc2 > > > > > > > > mysql > > > > mysql-connector-java > > 5.1.6 > > > > > > > > > > > > > > > > activityDB > > > > true > > > > > > > > > > > > activityDB > > > > > > com.dbdeploy > > maven-dbdeploy-plugin > > 3.0M3 > >
Re: Mvn commands are stalling
+1 Good comments. Might not be a bad idea to add a suggestion "Probable cause is missing version in your pom.xml " or "Probable cause is bad dependency definition for org.apache.maven.plugins:maven-compiler-plugin at line 85." I am not sure how the column number helps. What would be at column 15 of line 85 in this case? Ron On 09/01/2012 12:01 PM, Robert Scholte wrote: Hi, Even though I'm not a newbie, I can see 2 potential problems with this sentence: 1. line 84, column 15 of what? It doesn't mention the file. Sure, it always about the poms, but we're talking about unexperienced users here. 2. build.plugins.plugin.version ? This doesn't look like xml, so maybe you're not triggered to look inside the pom. And if you use a pom-editor, you may have never seen the xml. -Robert On Mon, 09 Jan 2012 15:39:54 +0100, Wayne Fay wrote: [WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 84, column 15 - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org -- Ron Wheeler President Artifact Software Inc email: rwhee...@artifact-software.com skype: ronaldmwheeler phone: 866-970-2435, ext 102 - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Mvn commands are stalling
Hi, Even though I'm not a newbie, I can see 2 potential problems with this sentence: 1. line 84, column 15 of what? It doesn't mention the file. Sure, it always about the poms, but we're talking about unexperienced users here. 2. build.plugins.plugin.version ? This doesn't look like xml, so maybe you're not triggered to look inside the pom. And if you use a pom-editor, you may have never seen the xml. -Robert On Mon, 09 Jan 2012 15:39:54 +0100, Wayne Fay wrote: [WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 84, column 15 - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Mvn commands are stalling
> Thanks Wayne for making me think :) I resolved the warning by editing the > pom. Do you think it is a reasonable/good error message or can be improved somehow (with the understanding that there are limits in what we can practically do)? Since most of us on this list are not Maven newbies, we have trouble looking at things from the newbie perspective sometimes. So any input you can provide would be appreciated. Wayne - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Mvn commands are stalling
> Update: It is working now. Turning off AVG did it! (... I think I may need > to figure out why and how AVG affects the mvn downloads, and come up with a > long term strategy to have both available at the same time, but for now I > am good!) I ran into this recently while helping some family migrate from an old eMachines running XP to a new Mac Mini with the "Migrate to Mac" wizard software. They had AVG which I had installed a long time ago and the wizard couldn't get through. If you check your TCP/IP stack, you will see an AVG Miniport Driver or something along those lines. Just click the checkbox to disable it. This is in Networking Properties for your LAN or Wifi device. There are other things in the list like File and Printer Sharing and Client for Microsoft Networks. You may be able to manage this via AVG Control Panel as well. Wayne - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Mvn commands are stalling
Update: It is working now. Turning off AVG did it! (... I think I may need to figure out why and how AVG affects the mvn downloads, and come up with a long term strategy to have both available at the same time, but for now I am good!) Thanks for your help!!! On Mon, Jan 9, 2012 at 10:20 AM, A R wrote: > Thanks Wayne for making me think :) I resolved the warning by editing the > pom. > > I looked up the anti-virus I have, and I only have AVG which I am not able > to turn off because of insufficient privileges. I am surprised by the fact > that re-running the command gets me a bit more further in the downloads > each time. If it is an antivirus, should it not always block the same > download? > > Thanks!! > > C:\development\Workspace1\project1>mvn eclipse:eclipse > [INFO] Scanning for projects... > [WARNING] The POM for > org.apache.maven.plugins:maven-compiler-plugin:jar:3.0.3 is missing, no > dependency information available > [WARNING] Failed to retrieve plugin descriptor for > org.apache.maven.plugins:maven-compiler-plugin:3.0.3: Plugin > org.apache.maven.plugins:maven-compile > r-plugin:3.0.3 or one of its dependencies could not be resolved: Failed to > read artifact descriptor for org.apache.maven.plugins:maven-compiler-plugin > :jar:3.0.3 > Downloading: > http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.8/maven-eclipse-plugin-2.8.jar > Terminate batch job (Y/N)? y > C:\development\Workspace1\project1>mvn eclipse:eclipse > [INFO] Scanning for projects... > Downloading: > http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.8/maven-eclipse-plugin-2.8.jar > Terminate batch job (Y/N)? y > C:\development\Workspace1\project1>mvn eclipse:eclipse > [INFO] Scanning for projects... > Downloading: > http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.8/maven-eclipse-plugin-2.8.jar > Downloaded: > http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.8/maven-eclipse-plugin-2.8.jar(202 > KB at 210.4 KB/sec) > [INFO] > [INFO] > > [INFO] Building Struts 2 Starter 1.0 > [INFO] > > [INFO] > [INFO] >>> maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 >>> > [INFO] > [INFO] <<< maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 <<< > [INFO] > [INFO] --- maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 --- > Downloading: > http://repo1.maven.org/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.pom > > Downloaded: > http://repo1.maven.org/maven2/org/eclipse/core/resources/3.3.0-v20070604/resources-3.3.0-v20070604.jar(663 > KB at 363.9 KB/sec) > Terminate batch job (Y/N)? y > C:\development\Workspace1\project1>mvn eclipse:eclipse > [INFO] Scanning for projects... > [INFO] > [INFO] > > [INFO] Building Struts 2 Starter 1.0 > [INFO] > > [INFO] > [INFO] >>> maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 >>> > [INFO] > [INFO] <<< maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 <<< > [INFO] > [INFO] --- maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 --- > Downloading: > http://repo1.maven.org/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar > Terminate batch job (Y/N)? y > C:\development\Workspace1\project1>mvn eclipse:eclipse > [INFO] Scanning for projects... > [INFO] > [INFO] > > [INFO] Building Struts 2 Starter 1.0 > [INFO] > > [INFO] > [INFO] >>> maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 >>> > [INFO] > [INFO] <<< maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 <<< > [INFO] > [INFO] --- maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 --- > Downloading: > http://repo1.maven.org/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar > Downloaded: > http://repo1.maven.org/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar(139 > KB at 174.3 KB/sec) > [INFO] Using Eclipse Workspace: C:\development\Workspace1 > [WARNING] Workspace defines a VM that does not contain a valid > jre/lib/rt.jar: C:\devtools\java7u2 > [INFO] Adding default classpath container: > org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5 > Downloading: > http://repo1.maven.org/maven2/commons-fileupload/commons-fileupload/1.1.1/commons-fileupload-1.1.1.pom > > Downloading: > http://repo1.maven.org/maven2/javax/servlet/servlet-api/2.4/servlet-api-2.4.jar > Terminate batch job (Y/N)? y > C:\development\Workspace1\project1>mvn eclipse:eclipse >
Re: Mvn commands are stalling
Thanks Wayne for making me think :) I resolved the warning by editing the pom. I looked up the anti-virus I have, and I only have AVG which I am not able to turn off because of insufficient privileges. I am surprised by the fact that re-running the command gets me a bit more further in the downloads each time. If it is an antivirus, should it not always block the same download? Thanks!! C:\development\Workspace1\project1>mvn eclipse:eclipse [INFO] Scanning for projects... [WARNING] The POM for org.apache.maven.plugins:maven-compiler-plugin:jar:3.0.3 is missing, no dependency information available [WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-compiler-plugin:3.0.3: Plugin org.apache.maven.plugins:maven-compile r-plugin:3.0.3 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-compiler-plugin :jar:3.0.3 Downloading: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.8/maven-eclipse-plugin-2.8.jar Terminate batch job (Y/N)? y C:\development\Workspace1\project1>mvn eclipse:eclipse [INFO] Scanning for projects... Downloading: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.8/maven-eclipse-plugin-2.8.jar Terminate batch job (Y/N)? y C:\development\Workspace1\project1>mvn eclipse:eclipse [INFO] Scanning for projects... Downloading: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.8/maven-eclipse-plugin-2.8.jar Downloaded: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.8/maven-eclipse-plugin-2.8.jar(202 KB at 210.4 KB/sec) [INFO] [INFO] [INFO] Building Struts 2 Starter 1.0 [INFO] [INFO] [INFO] >>> maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 >>> [INFO] [INFO] <<< maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 <<< [INFO] [INFO] --- maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 --- Downloading: http://repo1.maven.org/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.pom Downloaded: http://repo1.maven.org/maven2/org/eclipse/core/resources/3.3.0-v20070604/resources-3.3.0-v20070604.jar(663 KB at 363.9 KB/sec) Terminate batch job (Y/N)? y C:\development\Workspace1\project1>mvn eclipse:eclipse [INFO] Scanning for projects... [INFO] [INFO] [INFO] Building Struts 2 Starter 1.0 [INFO] [INFO] [INFO] >>> maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 >>> [INFO] [INFO] <<< maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 <<< [INFO] [INFO] --- maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 --- Downloading: http://repo1.maven.org/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar Terminate batch job (Y/N)? y C:\development\Workspace1\project1>mvn eclipse:eclipse [INFO] Scanning for projects... [INFO] [INFO] [INFO] Building Struts 2 Starter 1.0 [INFO] [INFO] [INFO] >>> maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 >>> [INFO] [INFO] <<< maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 <<< [INFO] [INFO] --- maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 --- Downloading: http://repo1.maven.org/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar Downloaded: http://repo1.maven.org/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar(139 KB at 174.3 KB/sec) [INFO] Using Eclipse Workspace: C:\development\Workspace1 [WARNING] Workspace defines a VM that does not contain a valid jre/lib/rt.jar: C:\devtools\java7u2 [INFO] Adding default classpath container: org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5 Downloading: http://repo1.maven.org/maven2/commons-fileupload/commons-fileupload/1.1.1/commons-fileupload-1.1.1.pom Downloading: http://repo1.maven.org/maven2/javax/servlet/servlet-api/2.4/servlet-api-2.4.jar Terminate batch job (Y/N)? y C:\development\Workspace1\project1>mvn eclipse:eclipse [INFO] Scanning for projects... [INFO] [INFO] [INFO] Building Struts 2 Starter 1.0 [INFO] [INFO] [INFO] >>> maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 >>> [INFO] [INFO] <<< maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 <<< [INFO] [INFO] --- maven-eclipse-plugin:2.8:eclipse (default-cli) @ project1 --- [INFO] Using Eclipse Workspace: C:\devel
Re: Mvn commands are stalling
> It almost seems like it is an internet connectivity problem, but I don't > see how it can be, when it can download some jars, but not the remaining > ones. ... > C:\development\workspace1\project1>dir This kind of problem is nearly always related to some antivirus software running on your Windows machine or on your network somewhere. Try turning it off or whitelisting the Java.exe process. > [WARNING] 'build.plugins.plugin.version' for > org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 84, > column 15 Well let's do a thought experiment. What do you think (as a new user to Maven) that error message means? As an experienced Maven user, it is super clear to me, but I'd like to hear what you are thinking. Wayne
Mvn commands are stalling
Hello, I am a relatively new user to Maven. I have Java 1.7 and Maven 3.0.3 installed. I am trying to fix two problems: 1. The first and more critical problem is: No matter what command I try to run, mvn starts the download and then it just stalls. The same thing happens when I try creating a project from an archetype. I tried running mvn help:effective-pom to resolve the warning in the snippet below, and that command also hangs just like the others. I have to use Ctrl-C to kill it and retry it again. It almost seems like it is an internet connectivity problem, but I don't see how it can be, when it can download some jars, but not the remaining ones. 2. I would like to know how I can resolve the warning below. Any help you can give is greatly appreciated. Thanks much!! AR -- C:\development\workspace1\project1>dir Volume in drive C has no label. Volume Serial Number is B894-5499 Directory of C:\development\workspace1\project1 12/29/2011 04:12 PM . 12/29/2011 04:12 PM .. 12/29/2011 04:12 PM 2,795 pom.xml 12/29/2011 04:12 PM src 1 File(s) 2,795 bytes 3 Dir(s) 582,170,943,488 bytes free C:\development\RFP\project1>mvn eclipse:eclipse [INFO] Scanning for projects... [WARNING] [WARNING] Some problems were encountered while building the effective model for com.dc:project1:war:1.0 [WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 84, column 15 [WARNING] [WARNING] It is highly recommended to fix these problems because they threaten the stability of your build. [WARNING] [WARNING] For this reason, future Maven versions might no longer support building such malformed projects. [WARNING] Downloading: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-surefire-plugin/2.7.2/maven-surefire-plugin-2.7.2.jar Downloaded: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-surefire-plugin/2.7.2/maven-surefire-plugin-2.7.2.jar(29 KB at 51.4 KB/sec) Downloading: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-war-plugin/2.1.1/maven-war-plugin-2.1.1.pom Downloaded: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-war-plugin/2.1.1/maven-war-plugin-2.1.1.pom(7 KB at 14.0 KB/sec) Downloading: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-war-plugin/2.1.1/maven-war-plugin-2.1.1.jar 62 KB
Re: Installation glitch!
Thank you Guillaume. Check my response to Thorsten. I have the maven install functioning now with the proper paths installed. -Original Message- From: Guillaume Polet Sent: Monday, January 09, 2012 10:35 AM To: Maven Users List Subject: Re: Installation glitch! Looks like mvn is not on your path (the purpose of step 2 thru 7 is to have, one way or another, the bin directory of Maven in your path variable). Note that after updating the environment variables you should open a new terminal and not reuse an existing one. If that is not your problem, could you post the output of the command set (just type 'set' without the single quotes in a terminal). Cheers, Guillaume Le 9/01/2012 11:15, MH a écrit : Hi I am a first time user of maven and new to open source in general. I have downloaded the latest version .bin file and followed the instructions “copied and pasted” below: Windows 2000/XP 1.. Unzip the distribution archive, i.e. apache-maven-3.0.3-bin.zip to the directory you wish to install Maven 3.0.3. These instructions assume you chose C:\Program Files\Apache Software Foundation. The subdirectory apache-maven-3.0.3 will be created from the archive. 2.. Add the M2_HOME environment variable by opening up the system properties (WinKey + Pause), selecting the "Advanced" tab, and the "Environment Variables" button, then adding the M2_HOME variable in the user variables with the value C:\Program Files\Apache Software Foundation\apache-maven-3.0.3. Be sure to omit any quotation marks around the path even if it contains spaces. Note: For Maven< 2.0.9, also be sure that the M2_HOME doesn't have a '\' as last character. 3.. In the same dialog, add the M2 environment variable in the user variables with the value %M2_HOME%\bin. 4.. Optional: In the same dialog, add the MAVEN_OPTS environment variable in the user variables to specify JVM properties, e.g. the value -Xms256m -Xmx512m. This environment variable can be used to supply extra options to Maven. 5.. In the same dialog, update/create the Path environment variable in the user variables and prepend the value %M2% to add Maven available in the command line. 6.. In the same dialog, make sure that JAVA_HOME exists in your user variables or in the system variables and it is set to the location of your JDK, e.g. C:\Program Files\Java\jdk1.5.0_02 and that %JAVA_HOME%\bin is in your Path environment variable. 7.. Open a new command prompt (Winkey + R then type cmd) and run mvn --version to verify that it is correctly installed. After running several different permutations and attempting to gain an expected response from the command prompt using mvn –version the system has proved to be not properly installed. The command mvn is not recognised. I have a standard Windows 7 install with a fairly standard AMD processor. Plenty of memory and disk space. Can anyone identify what might be causing this phenomenon on my machine? Many thanks Martin Harrison - 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
Re: Installation glitch!
Thanks Jeff I have it now. -Original Message- From: Jeff MAURY Sent: Monday, January 09, 2012 10:26 AM To: Maven Users List Subject: Re: Installation glitch! Probably because you have spaces in the directory where you installed Maven (C:\Program Files\Apache Software Foundation) Regards Jeff MAURY On Mon, Jan 9, 2012 at 11:15 AM, MH wrote: Hi I am a first time user of maven and new to open source in general. I have downloaded the latest version .bin file and followed the instructions “copied and pasted” below: Windows 2000/XP 1.. Unzip the distribution archive, i.e. apache-maven-3.0.3-bin.zip to the directory you wish to install Maven 3.0.3. These instructions assume you chose C:\Program Files\Apache Software Foundation. The subdirectory apache-maven-3.0.3 will be created from the archive. 2.. Add the M2_HOME environment variable by opening up the system properties (WinKey + Pause), selecting the "Advanced" tab, and the "Environment Variables" button, then adding the M2_HOME variable in the user variables with the value C:\Program Files\Apache Software Foundation\apache-maven-3.0.3. Be sure to omit any quotation marks around the path even if it contains spaces. Note: For Maven < 2.0.9, also be sure that the M2_HOME doesn't have a '\' as last character. 3.. In the same dialog, add the M2 environment variable in the user variables with the value %M2_HOME%\bin. 4.. Optional: In the same dialog, add the MAVEN_OPTS environment variable in the user variables to specify JVM properties, e.g. the value -Xms256m -Xmx512m. This environment variable can be used to supply extra options to Maven. 5.. In the same dialog, update/create the Path environment variable in the user variables and prepend the value %M2% to add Maven available in the command line. 6.. In the same dialog, make sure that JAVA_HOME exists in your user variables or in the system variables and it is set to the location of your JDK, e.g. C:\Program Files\Java\jdk1.5.0_02 and that %JAVA_HOME%\bin is in your Path environment variable. 7.. Open a new command prompt (Winkey + R then type cmd) and run mvn --version to verify that it is correctly installed. After running several different permutations and attempting to gain an expected response from the command prompt using mvn –version the system has proved to be not properly installed. The command mvn is not recognised. I have a standard Windows 7 install with a fairly standard AMD processor. Plenty of memory and disk space. Can anyone identify what might be causing this phenomenon on my machine? Many thanks Martin Harrison -- "Legacy code" often differs from its suggested alternative by actually working and scaling. - Bjarne Stroustrup http://www.jeffmaury.com http://riadiscuss.jeffmaury.com http://www.twitter.com/jeffmaury - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Installation glitch!
Hi Thorsten Right first time. I re-booted my machine and now I have maven functioning. The paths to both the maven install and the jdk are identified in the shell script. Many thanks Martin -Original Message- From: Thorsten Heit Sent: Monday, January 09, 2012 10:27 AM To: Maven Users List Subject: Re: Installation glitch! Hi, I am a first time user of maven and new to open source in general. Congrats and welcome! After running several different permutations and attempting to gain an expected response from the command prompt using mvn –version the system has proved to be not properly installed. The command mvn is not recognised. I have a standard Windows 7 install with a fairly standard AMD processor. Plenty of memory and disk space. Can anyone identify what might be causing this phenomenon on my machine? I assume you have installed Java on your machine...? Have you tried to logout and then login again before trying out "mvn --version"? Changing environment variables doesn't have any influence to already running programs... Regards Thorsten - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Installation glitch!
Looks like mvn is not on your path (the purpose of step 2 thru 7 is to have, one way or another, the bin directory of Maven in your path variable). Note that after updating the environment variables you should open a new terminal and not reuse an existing one. If that is not your problem, could you post the output of the command set (just type 'set' without the single quotes in a terminal). Cheers, Guillaume Le 9/01/2012 11:15, MH a écrit : Hi I am a first time user of maven and new to open source in general. I have downloaded the latest version .bin file and followed the instructions “copied and pasted” below: Windows 2000/XP 1.. Unzip the distribution archive, i.e. apache-maven-3.0.3-bin.zip to the directory you wish to install Maven 3.0.3. These instructions assume you chose C:\Program Files\Apache Software Foundation. The subdirectory apache-maven-3.0.3 will be created from the archive. 2.. Add the M2_HOME environment variable by opening up the system properties (WinKey + Pause), selecting the "Advanced" tab, and the "Environment Variables" button, then adding the M2_HOME variable in the user variables with the value C:\Program Files\Apache Software Foundation\apache-maven-3.0.3. Be sure to omit any quotation marks around the path even if it contains spaces. Note: For Maven< 2.0.9, also be sure that the M2_HOME doesn't have a '\' as last character. 3.. In the same dialog, add the M2 environment variable in the user variables with the value %M2_HOME%\bin. 4.. Optional: In the same dialog, add the MAVEN_OPTS environment variable in the user variables to specify JVM properties, e.g. the value -Xms256m -Xmx512m. This environment variable can be used to supply extra options to Maven. 5.. In the same dialog, update/create the Path environment variable in the user variables and prepend the value %M2% to add Maven available in the command line. 6.. In the same dialog, make sure that JAVA_HOME exists in your user variables or in the system variables and it is set to the location of your JDK, e.g. C:\Program Files\Java\jdk1.5.0_02 and that %JAVA_HOME%\bin is in your Path environment variable. 7.. Open a new command prompt (Winkey + R then type cmd) and run mvn --version to verify that it is correctly installed. After running several different permutations and attempting to gain an expected response from the command prompt using mvn –version the system has proved to be not properly installed. The command mvn is not recognised. I have a standard Windows 7 install with a fairly standard AMD processor. Plenty of memory and disk space. Can anyone identify what might be causing this phenomenon on my machine? Many thanks Martin Harrison - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Installation glitch!
Probably because you have spaces in the directory where you installed Maven (C:\Program Files\Apache Software Foundation) Regards Jeff MAURY On Mon, Jan 9, 2012 at 11:15 AM, MH wrote: > Hi > > I am a first time user of maven and new to open source in general. I have > downloaded the latest version .bin file and followed the instructions > “copied and pasted” below: > Windows 2000/XP > 1.. Unzip the distribution archive, i.e. apache-maven-3.0.3-bin.zip to > the directory you wish to install Maven 3.0.3. These instructions assume > you chose C:\Program Files\Apache Software Foundation. The subdirectory > apache-maven-3.0.3 will be created from the archive. > 2.. Add the M2_HOME environment variable by opening up the system > properties (WinKey + Pause), selecting the "Advanced" tab, and the > "Environment Variables" button, then adding the M2_HOME variable in the > user variables with the value C:\Program Files\Apache Software > Foundation\apache-maven-3.0.3. Be sure to omit any quotation marks around > the path even if it contains spaces. Note: For Maven < 2.0.9, also be sure > that the M2_HOME doesn't have a '\' as last character. > 3.. In the same dialog, add the M2 environment variable in the user > variables with the value %M2_HOME%\bin. > 4.. Optional: In the same dialog, add the MAVEN_OPTS environment variable > in the user variables to specify JVM properties, e.g. the value -Xms256m > -Xmx512m. This environment variable can be used to supply extra options to > Maven. > 5.. In the same dialog, update/create the Path environment variable in > the user variables and prepend the value %M2% to add Maven available in the > command line. > 6.. In the same dialog, make sure that JAVA_HOME exists in your user > variables or in the system variables and it is set to the location of your > JDK, e.g. C:\Program Files\Java\jdk1.5.0_02 and that %JAVA_HOME%\bin is in > your Path environment variable. > 7.. Open a new command prompt (Winkey + R then type cmd) and run mvn > --version to verify that it is correctly installed. > After running several different permutations and attempting to gain an > expected response from the command prompt using mvn –version the system > has proved to be not properly installed. The command mvn is not recognised. > I have a standard Windows 7 install with a fairly standard AMD processor. > Plenty of memory and disk space. > > Can anyone identify what might be causing this phenomenon on my machine? > > Many thanks > > Martin Harrison -- "Legacy code" often differs from its suggested alternative by actually working and scaling. - Bjarne Stroustrup http://www.jeffmaury.com http://riadiscuss.jeffmaury.com http://www.twitter.com/jeffmaury
Re: Installation glitch!
Hi, > I am a first time user of maven and new to open source in general. Congrats and welcome! > After running several different permutations and attempting to gain an > expected response from the command prompt using mvn –version the system > has proved to be not properly installed. The command mvn is not > recognised. I have a standard Windows 7 install with a fairly standard > AMD processor. Plenty of memory and disk space. > > Can anyone identify what might be causing this phenomenon on my machine? I assume you have installed Java on your machine...? Have you tried to logout and then login again before trying out "mvn --version"? Changing environment variables doesn't have any influence to already running programs... Regards Thorsten
Installation glitch!
Hi I am a first time user of maven and new to open source in general. I have downloaded the latest version .bin file and followed the instructions “copied and pasted” below: Windows 2000/XP 1.. Unzip the distribution archive, i.e. apache-maven-3.0.3-bin.zip to the directory you wish to install Maven 3.0.3. These instructions assume you chose C:\Program Files\Apache Software Foundation. The subdirectory apache-maven-3.0.3 will be created from the archive. 2.. Add the M2_HOME environment variable by opening up the system properties (WinKey + Pause), selecting the "Advanced" tab, and the "Environment Variables" button, then adding the M2_HOME variable in the user variables with the value C:\Program Files\Apache Software Foundation\apache-maven-3.0.3. Be sure to omit any quotation marks around the path even if it contains spaces. Note: For Maven < 2.0.9, also be sure that the M2_HOME doesn't have a '\' as last character. 3.. In the same dialog, add the M2 environment variable in the user variables with the value %M2_HOME%\bin. 4.. Optional: In the same dialog, add the MAVEN_OPTS environment variable in the user variables to specify JVM properties, e.g. the value -Xms256m -Xmx512m. This environment variable can be used to supply extra options to Maven. 5.. In the same dialog, update/create the Path environment variable in the user variables and prepend the value %M2% to add Maven available in the command line. 6.. In the same dialog, make sure that JAVA_HOME exists in your user variables or in the system variables and it is set to the location of your JDK, e.g. C:\Program Files\Java\jdk1.5.0_02 and that %JAVA_HOME%\bin is in your Path environment variable. 7.. Open a new command prompt (Winkey + R then type cmd) and run mvn --version to verify that it is correctly installed. After running several different permutations and attempting to gain an expected response from the command prompt using mvn –version the system has proved to be not properly installed. The command mvn is not recognised. I have a standard Windows 7 install with a fairly standard AMD processor. Plenty of memory and disk space. Can anyone identify what might be causing this phenomenon on my machine? Many thanks Martin Harrison