错误1:An error has occurred when creating this preference page
解决办法:
将环境变量Path中%JAVA_HOME%\bin;置于path最前面解决问题
错误2:webxml attribute is required
1
2
3
4
5
6
|
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-war-plugin:2.1.1:war (default-war) on project web_nanchang: Error assembling WAR: webxml attribute is required (or pre-existing WEB-INF/web.xml if executing in update mode) -> [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: |
解决:maven的web项目默认的webroot是在src\main\webapp。如果在此目录下找不到web.xml就抛出以上的异常。解决方法在pom.xml加入以下的配置。红色背景字体改成你网站的根目录。
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
< build >
< finalName >simple-webapp</ finalName >
< plugins >
< plugin >
< groupId >org.apache.maven.plugins</ groupId >
< artifactId >maven-war-plugin</ artifactId >
< version >2.1.1</ version >
< configuration >
< webResources >
< resource >
<!-- this is relative to the pom.xml directory --> < directory >WebContent</ directory >
</ resource >
</ webResources >
</ configuration >
</ plugin >
</ plugins >
</ build >
|
记录3:dependency引用本地jar包
1
2
3
4
5
6
7
|
< dependency >
< groupId >org.apache</ groupId >
< artifactId >test</ artifactId >
< version >1.0</ version >
< scope >system</ scope >
< systemPath >${basedir}/src/main/webapp/WEB-INF/lib/paypal_base.jar</ systemPath >
</ dependency >
|
maven使用module开发生成web工程,不打war包方法
1
|
mvn clean complie process-classes war:exploded
|
相关推荐
Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clean) on project
在<plugins></plugins>中添加<plugin> <groupId>org.apache.maven.plugins <artifactId>maven-compiler-plugin <version>3.8.1 <source>1.8 <target>1.8 </plugin>
<groupId>org.apache.tomcat.maven <artifactId>tomcat8-maven-plugin <version>3.0-r1655215 </plugin> ``` 但是,如果我们直接添加上面的依赖项,Maven 将无法找到该插件,因为该插件不存在于 Maven 的中央...
关于解决“Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1”问题,首先需要了解Maven的构建生命周期,以及Maven的编译插件(maven-compiler-plugin)如何在编译过程中发挥作用。...
maven-surefire-plugin-2.22.1.jar
maven-notice-plugin-1.0.1.jar
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-plugin-plugin:3.2:descriptor (default -descriptor) on project maven-project: Error extracting plugin descriptor: ‘No mojo definitions wer...
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-war-plugin:2.1.1:war (default-war) on project web_nanchang: Error assembling WAR: web.xml attribute is required (or pre-existing WEB-INF/...
然而,当出现错误 `[ERROR] Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:2.0.2.RELEASE:repackage (default) on project com.mutistic.boot` 时,这意味着Spring Boot的Maven插件在...
<goal>execute</goal> </plugin> </plugins> ``` 在这个例子中,`maven-db-plugin` 在 `process-resources` 阶段会执行 `create-db` 执行目标,并运行指定的 SQL 脚本。 需要注意的是,`googlecode` 已经...
CycloneDX Maven插件 CycloneDX Maven插件创建项目的所有直接和传递依赖项的集合,并创建有效的CycloneDX SBOM。 CycloneDX是一种轻量级的软件物料清单(SBOM)规范,旨在用于应用程序安全上下文和供应链组件分析。 ...
apt-maven-plugin提供Java 6 APT功能的Maven集成。 支持的目标是 process - to process main sources test-process - to process test sources 这是配置示例 <plugin> <groupId>com.mysema.maven</groupId> ...
spring-petclinic-master运行mvn install报错:Failed to execute goal io.spring.javaformat:spring-javaformat-maven-plugin:0.0.19:validate (default) on project spring-petclinic: Formatting violations ...
thingsboard编译错误 Failed to execute goal com.github.eirslett:frontend-maven-plugin:1.0:npm (npm install) on project js-executor: Failed to run task: 'npm install' failed. 该错误如果是3.0上的,请将...
前端行家插件 该插件在本地为您的项目下载/安装Node和NPM,运行npm install ,然后运行 , , , , 或任意组合。 它应该可以在Windows,OS X和Linux上运行。 如果您在获取节点软件包时比更喜欢 ,则此插件还可以...
Failed to execute goal org.apache.maven.plugins:maven-help-plugin:3.1.0:system (default-cli) on project standalone-pom: Execution default-cli of goal org.apache.maven.plugins:maven-help-plugin...
报错信息:[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.6.0:exec (gradle) on project spring-boot-gradle-plugin: Command execution failed.: Process exited with an error: 1 (Exit ...
标题 "sonarqube+maven+jenkins" 暗示了这个压缩包可能包含一个集成SonarQube、Maven和Jenkins的自动化代码质量管理流程的指南。这些工具在IT行业中广泛用于持续集成(CI)和持续交付(CD)实践,确保软件质量并提升...
在标题提到的`httpcomponents-client-4.2.5-bin.tar`中,我们找到了Apache HttpClient的特定版本4.2.5的二进制分发包,它通常包含了一系列的JAR文件,用于支持网络爬虫和其他需要与HTTP服务器交互的应用程序。...