mvn clean tomcat:run command

When I run "mvn clean tomcat:run" (without specifying any tomcat version) command from command prompt for running my web application, it download tomcat 6.0.29 version dependency as shown below:








pom.xml file of the application does not contain any tomcat version it require to run


So my query is how does it decide to download particular this tomcat version dependency.


Probably the default settings of the tomcat plugin you run.

Try running mvn tomcat:help -Ddetails to see what version of the plugin you use, and how it can be configured.

I think it is an earlier version of the plugin, and you can now use explicit versions, such as

mvn org.apache.tomcat.maven:tomcat6-maven-plugin:2.0:run
mvn org.apache.tomcat.maven:tomcat7-maven-plugin:2.0:run

(or the shorter form)

Seems, you are running the tomcat-maven-plugin from codehaus, whihc has tomcat 6.0.29 built-in. (Seems there was no activity since 2010.) You should try the tomcat7 plugin from apache.

Regards Tibor

In command line for maven use --debug option to get explanation of build process. For our case output looks like:

...[DEBUG] Resolving plugin prefix tomcat from [org.apache.maven.plugins, org.codehaus.mojo] ... [DEBUG] Resolved plugin version for org.codehaus.mojo:tomcat-maven-plugin to 1.1 from repository central (, releases)...

Actually to explain why we've got tomcat v1.1 without specifying anything about tomcat, remember that maven build process has been customized with build plugins. And each build plugins has own build plugins. So it is enough to examine effective pom file to get clear understanding that almost empty initial pom.xml has quite big effective pom.xml.

To overcome issue just use explicit version of the tomcat plugin.

Need Your Help

apache ProxyPass: how to preserve original IP address

apache redirect proxypass

We are using ProxyPass to redirect all "/r" requests to jboss on port 18080 as follows:

drawString prints string over a screenshot of my current window

java swing jframe paint

When I run this code in Eclipse I get a the string and line printing in a new windows, but instead of a blank window it simply is a screenshot of my current window, set to the size I declare.