maven 构建在复制 Web 应用程序资源时被终止而没有任何错误
maven build gets terminated while copying web app resources without any error
我正在尝试使用全新安装进行 maven 构建。一切顺利,但最后在复制 Web 应用程序资源以创建 war 时..构建被终止而没有错误。有什么建议吗
已终止快照
终止快照二
enter image description here
编辑:这是我的 pom.xml
<project xmlns="maven.apache.org/POM/4.0.0" xmlns:xsi="w3.org/2001/XMLSchema-instance" xsi:schemaLocation="maven.apache.org/POM/4.0.0 maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.mg.mc</groupId>
<artifactId>Management-core</artifactId>
<version>${releaseVersion}</version>
</parent>
<groupId>com.mg.mc</groupId>
<artifactId>ManagementServices</artifactId>
<packaging>war</packaging>
<name>ManagementServices</name>
<dependencies>
<dependency>
<groupId>com.mg.mc</groupId>
<artifactId>ManagementExternalJaxb</artifactId>
</dependency>
<dependency>
<groupId>com.mg.mc</groupId>
<artifactId>ManagementJaxb</artifactId>
</dependency>
<dependency>
<groupId>com.mg.mc</groupId>
<artifactId>ManagementServiceApi</artifactId>
<type>ejb</type>
</dependency>
</dependencies>
<build>
<defaultGoal>install</defaultGoal>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.3</version>
<executions>
<execution>
<id>unpack</id>
<phase>process-resources</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>com.mg.mc</groupId>
<artifactId>ManagementServices</artifactId>
<version>${ManagementServices.customer.version}</version>
<type>war</type>
<overWrite>true</overWrite>
<outputDirectory>target/${releaseVersion}/war/</outputDirectory>
<excludes>**/EnterpriseSharedResources*.jar, */EnterpriseInboundListeners.jar</excludes>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>3.3.1</version>
<configuration>
<warSourceDirectory>target/${releaseVersion}/war/</warSourceDirectory>
</configuration>
</plugin>
</plugins>
</build>
</project>
根据文档,maven-dependency-plugin
插件的 unpack
目标默认绑定到 process-sources
阶段。
那么您能否更改(或删除)插件配置中的 <phase>process-resources</phase>
我正在尝试使用全新安装进行 maven 构建。一切顺利,但最后在复制 Web 应用程序资源以创建 war 时..构建被终止而没有错误。有什么建议吗
已终止快照
终止快照二
enter image description here
编辑:这是我的 pom.xml
<project xmlns="maven.apache.org/POM/4.0.0" xmlns:xsi="w3.org/2001/XMLSchema-instance" xsi:schemaLocation="maven.apache.org/POM/4.0.0 maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.mg.mc</groupId>
<artifactId>Management-core</artifactId>
<version>${releaseVersion}</version>
</parent>
<groupId>com.mg.mc</groupId>
<artifactId>ManagementServices</artifactId>
<packaging>war</packaging>
<name>ManagementServices</name>
<dependencies>
<dependency>
<groupId>com.mg.mc</groupId>
<artifactId>ManagementExternalJaxb</artifactId>
</dependency>
<dependency>
<groupId>com.mg.mc</groupId>
<artifactId>ManagementJaxb</artifactId>
</dependency>
<dependency>
<groupId>com.mg.mc</groupId>
<artifactId>ManagementServiceApi</artifactId>
<type>ejb</type>
</dependency>
</dependencies>
<build>
<defaultGoal>install</defaultGoal>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.3</version>
<executions>
<execution>
<id>unpack</id>
<phase>process-resources</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>com.mg.mc</groupId>
<artifactId>ManagementServices</artifactId>
<version>${ManagementServices.customer.version}</version>
<type>war</type>
<overWrite>true</overWrite>
<outputDirectory>target/${releaseVersion}/war/</outputDirectory>
<excludes>**/EnterpriseSharedResources*.jar, */EnterpriseInboundListeners.jar</excludes>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>3.3.1</version>
<configuration>
<warSourceDirectory>target/${releaseVersion}/war/</warSourceDirectory>
</configuration>
</plugin>
</plugins>
</build>
</project>
根据文档,maven-dependency-plugin
插件的 unpack
目标默认绑定到 process-sources
阶段。
那么您能否更改(或删除)插件配置中的 <phase>process-resources</phase>