I am trying to create a Jave Web project with following Maven command
mvn archetype:generate -DgroupId=com.mazhar.event -DartifactId=EventBook2 -DarchetypeArtifactId=maven-archetype-webapp -DinteractiveMode=false
and the process is stuck on Genrating project in batch mode
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Maven Stub Project (No POM) 1
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] >>> maven-archetype-plugin:2.3:generate (default-cli) @ standalone-pom >>>
[INFO]
[INFO] <<< maven-archetype-plugin:2.3:generate (default-cli) @ standalone-pom <<<
[INFO]
[INFO] --- maven-archetype-plugin:2.3:generate (default-cli) @ standalone-pom ---
[INFO] Generating project in Batch mode
Here is my system details
mvn -vsersion
Apache Maven 3.1.1 (0728685237757ffbf44136acec0402957f723d9a; 2013-09-17 20:22:22+0500)
Maven home: D:\servers\apache-maven\bin\..
Java version: 1.6.0_32, vendor: Sun Microsystems Inc.
Java home: C:\Program Files (x86)\Java\jdk1.6.0_32\jre
Default locale: en_US, platform encoding: Cp1252
OS name: "windows 7", version: "6.1", arch: "x86", family: "windows"
Add -X
to your command to enable Maven's debug logging.
If it's stuck on something like
[DEBUG] Searching for remote catalog: http://repo.maven.apache.org/maven2/archetype-catalog.xml
you probably have a connection problem. Since it has been working for you before, you obviously don't need to configure a proxy. Instead - since you are using Windows - my guess is, that your virus scanner/personal firewall is blocking or rather "scanning" the connection, resulting in a slow response. Try temporarily disabling your virus scanner/personal firewall and see if that helps.
You can simply use local archetype-catalog.xml file instead of the remote one.
The option -DarchetypeCatalog=internal
can do it well.
So, you are going to generate your project instantly now:
mvn -B archetype:generate -DarchetypeCatalog=internal -DgroupId=com.mycompany.app -DartifactId=my-app
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With