首页 > 解决方案 > 未能执行目标 org.eclipse.jetty:jetty-maven-plugin:9.4.8.v20171121:run

问题描述

我正在使用 jettty 作为 maven 插件做一个 JavaEE HelloWorld 应用程序。当我尝试运行码头时,我收到以下错误:

Failed to execute goal org.eclipse.jetty:jetty-maven-plugin:9.4.8.v20171121:run (default-cli) on project HomeShop: Failure

这是我的 pom.xml

<?xml version="1.0" encoding="UTF-8"?>
 <project xmlns="http://maven.apache.org/POM/4.0.0"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>groupId</groupId>
<artifactId>HomeShop</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>war</packaging>
<build>
    <plugins>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <configuration>
                <source>1.8</source>
                <target>1.8</target>
            </configuration>
            <version>3.7.0</version>
        </plugin>
        <plugin>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-maven-plugin</artifactId>
            <version>9.4.8.v20171121</version>
            <configuration>
                <scanIntervalSeconds>1</scanIntervalSeconds>
            </configuration>
        </plugin>
    </plugins>
</build>
enter code here
<dependencies>
    <!-- https://mvnrepository.com/artifact/javax.servlet/javax.servlet-api -->
    <dependency>
        <groupId>javax.servlet</groupId>
        <artifactId>javax.servlet-api</artifactId>
        <version>3.1.0</version>
        <scope>provided</scope>
    </dependency>
</dependencies>

我正在使用 IntelliJ

有人可以帮我解决这个问题

标签: mavenjakarta-eejetty

解决方案


推荐阅读