我想尝试使用Grails 2.1.1附带的maven功能。
所以我使用grails create-app
创建了一个简单的grails项目。之后,我运行了
项目目录中grails create-pom
。现在我拨打mvn package
并收到大量错误文字。
[INFO] Scanning for projects...
[WARNING] The POM for org.springframework.uaa:org.springframework.uaa.client:jar:1.0.1.RELEASE is missing, no dependency information available
[WARNING]
[WARNING] Some problems were encountered while building the effective model for de.myapp:simple-grails-app:grails-app:0.1
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-surefire-plugin is missing. @ line 97, column 21
[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]
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building simple-grails-app 0.1
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- grails-maven-plugin:2.1.1:validate (default-validate) @ simple-grails-app ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.662s
[INFO] Finished at: Sat Oct 20 16:34:40 CEST 2012
[INFO] Final Memory: 10M/110M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.grails:grails-maven-plugin:2.1.1:validate (default-validate) on project simple-grails-app: Execution default-validate of goal org.grails:grails-maven-plugin:2.1.1:validate failed: A required class was missing while executing org.grails:grails-maven-plugin:2.1.1:validate: grails/util/Metadata
[ERROR] -----------------------------------------------------
[ERROR] realm = plugin>org.grails:grails-maven-plugin:2.1.1
[ERROR] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
[ERROR] urls[0] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-maven-plugin/2.1.1/grails-maven-plugin-2.1.1.jar
[ERROR] urls[1] = file:/C:/Users/Flo(Admin)/.m2/repository/jline/jline/1.0/jline-1.0.jar
[ERROR] urls[2] = file:/C:/Users/Flo(Admin)/.m2/repository/org/codehaus/groovy/groovy-all/1.8.8/groovy-all-1.8.8.jar
[ERROR] urls[3] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-bootstrap/2.1.1/grails-bootstrap-2.1.1.jar
[ERROR] urls[4] = file:/C:/Users/Flo(Admin)/.m2/repository/org/fusesource/jansi/jansi/1.2.1/jansi-1.2.1.jar
[ERROR] urls[5] = file:/C:/Users/Flo(Admin)/.m2/repository/com/google/protobuf/protobuf-java/2.4.1/protobuf-java-2.4.1.jar
[ERROR] urls[6] = file:/C:/Users/Flo(Admin)/.m2/repository/org/bouncycastle/bcpg-jdk15/1.45/bcpg-jdk15-1.45.jar
[ERROR] urls[7] = file:/C:/Users/Flo(Admin)/.m2/repository/org/bouncycastle/bcprov-jdk15/1.45/bcprov-jdk15-1.45.jar
[ERROR] urls[8] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/ant/ant-launcher/1.8.2/ant-launcher-1.8.2.jar
[ERROR] urls[9] = file:/C:/Users/Flo(Admin)/.m2/repository/javax/servlet/javax.servlet-api/3.0.1/javax.servlet-api-3.0.1.jar
[ERROR] urls[10] = file:/C:/Users/Flo(Admin)/.m2/repository/org/slf4j/slf4j-api/1.6.2/slf4j-api-1.6.2.jar
[ERROR] urls[11] = file:/C:/Users/Flo(Admin)/.m2/repository/junit/junit/4.10/junit-4.10.jar
[ERROR] urls[12] = file:/C:/Users/Flo(Admin)/.m2/repository/org/hamcrest/hamcrest-core/1.1/hamcrest-core-1.1.jar
[ERROR] urls[13] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-beans/3.1.2.RELEASE/spring-beans-3.1.2.RELEASE.jar
[ERROR] urls[14] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-context/3.1.2.RELEASE/spring-context-3.1.2.RELEASE.jar
[ERROR] urls[15] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-test/3.1.2.RELEASE/spring-test-3.1.2.RELEASE.jar
[ERROR] urls[16] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-context-support/3.1.2.RELEASE/spring-context-support-3.1.2.RELEASE.jar
[ERROR] urls[17] = file:/C:/Users/Flo(Admin)/.m2/repository/com/googlecode/json-simple/json-simple/1.1/json-simple-1.1.jar
[ERROR] urls[18] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/ant/ant/1.8.2/ant-1.8.2.jar
[ERROR] urls[19] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-core/3.1.2.RELEASE/spring-core-3.1.2.RELEASE.jar
[ERROR] urls[20] = file:/C:/Users/Flo(Admin)/.m2/repository/org/slf4j/jcl-over-slf4j/1.6.2/jcl-over-slf4j-1.6.2.jar
[ERROR] urls[21] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/ivy/ivy/2.2.0/ivy-2.2.0.jar
[ERROR] urls[22] = file:/C:/Users/Flo(Admin)/.m2/repository/org/hibernate/javax/persistence/hibernate-jpa-2.0-api/1.0.1.Final/hibernate-jpa-2.0-api-1.0.1.Final.jar
[ERROR] urls[23] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/ant/ant-trax/1.7.1/ant-trax-1.7.1.jar
[ERROR] urls[24] = file:/C:/Users/Flo(Admin)/.m2/repository/net/java/dev/jna/jna/3.2.3/jna-3.2.3.jar
[ERROR] urls[25] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/ant/ant-junit/1.8.2/ant-junit-1.8.2.jar
[ERROR] urls[26] = file:/C:/Users/Flo(Admin)/.m2/repository/commons-lang/commons-lang/2.6/commons-lang-2.6.jar
[ERROR] urls[27] = file:/C:/Users/Flo(Admin)/.m2/repository/org/codehaus/gant/gant_groovy1.8/1.9.6/gant_groovy1.8-1.9.6.jar
[ERROR] urls[28] = file:/C:/Users/Flo(Admin)/.m2/repository/commons-cli/commons-cli/1.2/commons-cli-1.2.jar
[ERROR] urls[29] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-launcher/1.0.5/grails-launcher-1.0.5.jar
[ERROR] urls[30] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-core/2.1.1/grails-core-2.1.1.jar
[ERROR] urls[31] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-expression/3.1.2.RELEASE/spring-expression-3.1.2.RELEASE.jar
[ERROR] urls[32] = file:/C:/Users/Flo(Admin)/.m2/repository/commons-collections/commons-collections/3.2.1/commons-collections-3.2.1.jar
[ERROR] urls[33] = file:/C:/Users/Flo(Admin)/.m2/repository/commons-io/commons-io/2.1/commons-io-2.1.jar
[ERROR] urls[34] = file:/C:/Users/Flo(Admin)/.m2/repository/com/googlecode/concurrentlinkedhashmap/concurrentlinkedhashmap-lru/1.2_jdk5/concurrentlinkedhashmap-lru-1.2_jdk5.jar
[ERROR] urls[35] = file:/C:/Users/Flo(Admin)/.m2/repository/oro/oro/2.0.8/oro-2.0.8.jar
[ERROR] urls[36] = file:/C:/Users/Flo(Admin)/.m2/repository/xalan/serializer/2.7.1/serializer-2.7.1.jar
[ERROR] urls[37] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-aop/3.1.2.RELEASE/spring-aop-3.1.2.RELEASE.jar
[ERROR] urls[38] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-jms/3.1.2.RELEASE/spring-jms-3.1.2.RELEASE.jar
[ERROR] urls[39] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-web/3.1.2.RELEASE/spring-web-3.1.2.RELEASE.jar
[ERROR] urls[40] = file:/C:/Users/Flo(Admin)/.m2/repository/org/aspectj/aspectjrt/1.6.10/aspectjrt-1.6.10.jar
[ERROR] urls[41] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-tx/3.1.2.RELEASE/spring-tx-3.1.2.RELEASE.jar
[ERROR] urls[42] = file:/C:/Users/Flo(Admin)/.m2/repository/org/aspectj/aspectjweaver/1.6.10/aspectjweaver-1.6.10.jar
[ERROR] urls[43] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-asm/3.1.2.RELEASE/spring-asm-3.1.2.RELEASE.jar
[ERROR] urls[44] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails/2.1.1/grails-2.1.1.jar
[ERROR] urls[45] = file:/C:/Users/Flo(Admin)/.m2/repository/asm/asm/3.1/asm-3.1.jar
[ERROR] urls[46] = file:/C:/Users/Flo(Admin)/.m2/repository/cglib/cglib/2.2/cglib-2.2.jar
[ERROR] urls[47] = file:/C:/Users/Flo(Admin)/.m2/repository/aopalliance/aopalliance/1.0/aopalliance-1.0.jar
[ERROR] urls[48] = file:/C:/Users/Flo(Admin)/.m2/repository/commons-validator/commons-validator/1.3.1/commons-validator-1.3.1.jar
[ERROR] urls[49] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-aspects/3.1.2.RELEASE/spring-aspects-3.1.2.RELEASE.jar
[ERROR] urls[50] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-web/2.1.1/grails-web-2.1.1.jar
[ERROR] urls[51] = file:/C:/Users/Flo(Admin)/.m2/repository/taglibs/standard/1.1.2/standard-1.1.2.jar
[ERROR] urls[52] = file:/C:/Users/Flo(Admin)/.m2/repository/commons-fileupload/commons-fileupload/1.2.2/commons-fileupload-1.2.2.jar
[ERROR] urls[53] = file:/C:/Users/Flo(Admin)/.m2/repository/xpp3/xpp3_min/1.1.4c/xpp3_min-1.1.4c.jar
[ERROR] urls[54] = file:/C:/Users/Flo(Admin)/.m2/repository/javax/servlet/jstl/1.1.2/jstl-1.1.2.jar
[ERROR] urls[55] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-spring/2.1.1/grails-spring-2.1.1.jar
[ERROR] urls[56] = file:/C:/Users/Flo(Admin)/.m2/repository/commons-el/commons-el/1.0/commons-el-1.0.jar
[ERROR] urls[57] = file:/C:/Users/Flo(Admin)/.m2/repository/opensymphony/sitemesh/2.4/sitemesh-2.4.jar
[ERROR] urls[58] = file:/C:/Users/Flo(Admin)/.m2/repository/commons-beanutils/commons-beanutils/1.8.3/commons-beanutils-1.8.3.jar
[ERROR] urls[59] = file:/C:/Users/Flo(Admin)/.m2/repository/javax/servlet/jsp-api/2.0/jsp-api-2.0.jar
[ERROR] urls[60] = file:/C:/Users/Flo(Admin)/.m2/repository/org/springframework/spring-webmvc/3.1.2.RELEASE/spring-webmvc-3.1.2.RELEASE.jar
[ERROR] urls[61] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-scripts/2.1.1/grails-scripts-2.1.1.jar
[ERROR] urls[62] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-plugin-controllers/2.1.1/grails-plugin-controllers-2.1.1.jar
[ERROR] urls[63] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-plugin-testing/2.1.1/grails-plugin-testing-2.1.1.jar
[ERROR] urls[64] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-datastore-simple/1.1.0.RELEASE/grails-datastore-simple-1.1.0.RELEASE.jar
[ERROR] urls[65] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-datastore-gorm/1.1.0.RELEASE/grails-datastore-gorm-1.1.0.RELEASE.jar
[ERROR] urls[66] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-test/1.3.7/grails-test-1.3.7.jar
[ERROR] urls[67] = file:/C:/Users/Flo(Admin)/.m2/repository/org/slf4j/jul-to-slf4j/1.5.8/jul-to-slf4j-1.5.8.jar
[ERROR] urls[68] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-plugin-converters/2.1.1/grails-plugin-converters-2.1.1.jar
[ERROR] urls[69] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-plugin-gsp/2.1.1/grails-plugin-gsp-2.1.1.jar
[ERROR] urls[70] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-plugin-codecs/2.1.1/grails-plugin-codecs-2.1.1.jar
[ERROR] urls[71] = file:/C:/Users/Flo(Admin)/.m2/repository/commons-codec/commons-codec/1.5/commons-codec-1.5.jar
[ERROR] urls[72] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-plugin-filters/2.1.1/grails-plugin-filters-2.1.1.jar
[ERROR] urls[73] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-datastore-core/1.1.0.RELEASE/grails-datastore-core-1.1.0.RELEASE.jar
[ERROR] urls[74] = file:/C:/Users/Flo(Admin)/.m2/repository/javassist/javassist/3.12.0.GA/javassist-3.12.0.GA.jar
[ERROR] urls[75] = file:/C:/Users/Flo(Admin)/.m2/repository/javax/transaction/jta/1.1/jta-1.1.jar
[ERROR] urls[76] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-plugin-servlets/2.1.1/grails-plugin-servlets-2.1.1.jar
[ERROR] urls[77] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-plugin-mimetypes/2.1.1/grails-plugin-mimetypes-2.1.1.jar
[ERROR] urls[78] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-plugin-domain-class/2.1.1/grails-plugin-domain-class-2.1.1.jar
[ERROR] urls[79] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-logging/2.1.1/grails-logging-2.1.1.jar
[ERROR] urls[80] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-crud/2.1.1/grails-crud-2.1.1.jar
[ERROR] urls[81] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-resources/2.1.1/grails-resources-2.1.1.jar
[ERROR] urls[82] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-plugin-tomcat/2.1.1/grails-plugin-tomcat-2.1.1.jar
[ERROR] urls[83] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/embed/tomcat-embed-logging-juli/7.0.30/tomcat-embed-logging-juli-7.0.30.jar
[ERROR] urls[84] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/embed/tomcat-embed-logging-log4j/7.0.30/tomcat-embed-logging-log4j-7.0.30.jar
[ERROR] urls[85] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/tomcat-catalina-ant/7.0.30/tomcat-catalina-ant-7.0.30.jar
[ERROR] urls[86] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/tomcat-coyote/7.0.30/tomcat-coyote-7.0.30.jar
[ERROR] urls[87] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/tomcat-juli/7.0.30/tomcat-juli-7.0.30.jar
[ERROR] urls[88] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/tomcat-util/7.0.30/tomcat-util-7.0.30.jar
[ERROR] urls[89] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/tomcat-catalina/7.0.30/tomcat-catalina-7.0.30.jar
[ERROR] urls[90] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/tomcat-servlet-api/7.0.30/tomcat-servlet-api-7.0.30.jar
[ERROR] urls[91] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/tomcat-annotations-api/7.0.30/tomcat-annotations-api-7.0.30.jar
[ERROR] urls[92] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/tomcat-api/7.0.30/tomcat-api-7.0.30.jar
[ERROR] urls[93] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/embed/tomcat-embed-core/7.0.30/tomcat-embed-core-7.0.30.jar
[ERROR] urls[94] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/tomcat/embed/tomcat-embed-jasper/7.0.30/tomcat-embed-jasper-7.0.30.jar
[ERROR] urls[95] = file:/C:/Users/Flo(Admin)/.m2/repository/org/eclipse/jdt/core/compiler/ecj/3.7.1/ecj-3.7.1.jar
[ERROR] urls[96] = file:/C:/Users/Flo(Admin)/.m2/repository/org/grails/grails-maven-archetype/2.1.1/grails-maven-archetype-2.1.1.jar
[ERROR] urls[97] = file:/C:/Users/Flo(Admin)/.m2/repository/org/apache/maven/maven-archiver/2.2/maven-archiver-2.2.jar
[ERROR] urls[98] = file:/C:/Users/Flo(Admin)/.m2/repository/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar
[ERROR] urls[99] = file:/C:/Users/Flo(Admin)/.m2/repository/org/codehaus/plexus/plexus-utils/1.4.5/plexus-utils-1.4.5.jar
[ERROR] urls[100] = file:/C:/Program%20Files/Java/jdk1.6.0_35/jre/../lib/tools.jar
[ERROR] Number of foreign imports: 1
[ERROR] import: Entry[import from realm ClassRealm[project>de.myapp:simple-grails-app:0.1, parent: ClassRealm[maven.api, parent: null]]]
[ERROR]
[ERROR] -----------------------------------------------------: grails.util.Metadata
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginContainerException
我错过了什么?