Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/maven/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java Intellij Maven项目-缺少插件_Java_Maven_Intellij Idea_Maven Plugin - Fatal编程技术网

Java Intellij Maven项目-缺少插件

Java Intellij Maven项目-缺少插件,java,maven,intellij-idea,maven-plugin,Java,Maven,Intellij Idea,Maven Plugin,我的maven项目插件是红色的,它们不会下载。如何解决这个问题?以下是maven intellij项目的图片: 下面是我的pom.xml文件内容: <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项目插件是红色的,它们不会下载。如何解决这个问题?以下是maven intellij项目的图片:

下面是我的pom.xml文件内容:

    <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/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <groupId>com.example.ema</groupId>
  <artifactId>jerseyexample</artifactId>
  <packaging>war</packaging>
  <version>1.0-SNAPSHOT</version>
  <name>jerseyexample Maven Webapp</name>
  <url>http://maven.apache.org</url>
  <dependencies>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>3.8.1</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.glassfish.jersey.containers</groupId>
      <artifactId>jersey-container-servlet</artifactId>
      <version>2.10.1</version>
    </dependency>


  </dependencies>



  <build>
    <finalName>jerseyexample</finalName>
    <plugins>
      <plugin>
        <groupId>org.apache.tomcat.maven</groupId>
        <artifactId>tomcat7-maven-plugin</artifactId>
        <version>2.2</version>
        <configuration>
          <server>TomcatServer</server>
          <path>/newjersey</path>
        </configuration>
      </plugin>
    </plugins>


  </build>
</project>

4.0.0
com.example.ema
球衣示例
战争
1.0-快照
JerseyMaven Webapp示例
http://maven.apache.org
朱尼特
朱尼特
3.8.1
测试
org.glassfish.jersey.containers
jersey容器servlet
2.10.1
球衣示例
org.apache.tomcat.maven
tomcat7 maven插件
2.2
TomcatServer
/新泽西州
我将鼠标放在名为“jerseyexample maven Webapp”的图像中的第一个maven目录上,它显示了以下错误,希望这有帮助:

下面是我如何添加jersey依赖项的。。。我只是下载了jar文件并将其添加到应用程序模块:


问题在于maven用于构建项目的my settings.xml文件。我在那里定义了一个使用代理的镜像,它阻止了下载

我想你已经注意到你没有执行
也尝试过强制重新导入这些插件吗?首先,您应该尝试在命令行中使用Maven下载这些插件,以验证这是IDEA问题还是Maven/系统问题。您现在是否需要从命令行安装插件的命令。我真正需要的是tomcat7 Maven插件。请从IntelliJ内部和命令行外部尝试
mvn clean install