2016-06-20 7 views
0

해결 방법을 모르는 문제가 있습니다. Eclipse 프로젝트를 가져오고 싶습니다. 그러나 나는 내가 이클립스에서 다음과 같은 오류가 받고있는 중이 야 때 나는 터미널에서 "MVN 설치"를하고있는 중이 야 때Eclipse에서 Maven 프로젝트를 가져 오는 중 오류가 발생했습니다.

enter image description here

을하지만, 성공적으로 프로젝트를 빌드 할 수 있어요. 다음은 pom.xml 파일입니다 : gmaven 이클립스에 문제가있는 것처럼

<?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>com.thinkaurelius.titan</groupId> 
    <artifactId>titan-web-example</artifactId> 
    <version>1.0-SNAPSHOT</version> 
    <packaging>war</packaging> 

    <description> 
     This is a simple web app example. 
    </description> 
    <licenses> 
     <license> 
      <name>The Apache Software License, Version 2.0</name> 
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url> 
     </license> 
    </licenses> 

    <properties> 
     <spring.version>4.0.3.RELEASE</spring.version> 
     <titan.version>1.0.0</titan.version> 
    </properties> 

    <dependencies> 

     <dependency> 
      <groupId>com.thinkaurelius.titan</groupId> 
      <artifactId>titan-cassandra</artifactId> 
      <version>${titan.version}</version> 
      <exclusions> 
       <!-- These don't play well w/ the web classesthatrunthings deps below --> 
       <exclusion> 
        <groupId>org.mortbay.jetty</groupId> 
        <artifactId>servlet-api</artifactId> 
       </exclusion> 
       <exclusion> 
        <groupId>javax.servlet</groupId> 
        <artifactId>servlet-api</artifactId> 
       </exclusion> 
      </exclusions> 
     </dependency> 

     <dependency> 
      <groupId>com.thinkaurelius.titan</groupId> 
      <artifactId>titan-es</artifactId> 
      <version>${titan.version}</version> 
     </dependency> 

     <dependency> 
      <groupId>org.apache.tinkerpop</groupId> 
      <artifactId>gremlin-groovy</artifactId> 
      <version>3.0.0-incubating</version> 
     </dependency> 


     <!-- Web App --> 
     <dependency> 
      <groupId>org.springframework</groupId> 
      <artifactId>spring-core</artifactId> 
      <version>${spring.version}</version> 
     </dependency> 

     <dependency> 
      <groupId>org.springframework</groupId> 
      <artifactId>spring-context</artifactId> 
      <version>${spring.version}</version> 
     </dependency> 

     <dependency> 
      <groupId>org.jboss.resteasy</groupId> 
      <artifactId>jaxrs-api</artifactId> 
      <version>2.2.1.GA</version> 
     </dependency> 

     <dependency> 
      <groupId>com.sun.jersey</groupId> 
      <artifactId>jersey-server</artifactId> 
      <version>1.18.1</version> 
     </dependency> 

     <dependency> 
      <groupId>com.sun.jersey</groupId> 
      <artifactId>jersey-json</artifactId> 
      <version>1.18.1</version> 
     </dependency> 

     <dependency> 
      <groupId>org.springframework</groupId> 
      <artifactId>spring-web</artifactId> 
      <version>${spring.version}</version> 
     </dependency> 

     <dependency> 
      <groupId>org.springframework</groupId> 
      <artifactId>spring-aop</artifactId> 
      <version>${spring.version}</version> 
     </dependency> 

     <!-- Jersey --> 
     <dependency> 
      <groupId>com.sun.jersey.contribs</groupId> 
      <artifactId>jersey-spring</artifactId> 
      <version>1.18.1</version> 
      <exclusions> 
       <!-- oh maven you crazy old bird! --> 
       <exclusion> 
        <groupId>org.springframework</groupId> 
        <artifactId>spring</artifactId> 
       </exclusion> 
       <exclusion> 
        <groupId>org.springframework</groupId> 
        <artifactId>spring-core</artifactId> 
       </exclusion> 
       <exclusion> 
        <groupId>org.springframework</groupId> 
        <artifactId>spring-web</artifactId> 
       </exclusion> 
       <exclusion> 
        <groupId>org.springframework</groupId> 
        <artifactId>spring-beans</artifactId> 
       </exclusion> 
       <exclusion> 
        <groupId>org.springframework</groupId> 
        <artifactId>spring-context</artifactId> 
       </exclusion> 
       <exclusion> 
        <groupId>org.springframework</groupId> 
        <artifactId>spring-aop</artifactId> 
       </exclusion> 
      </exclusions> 
     </dependency> 

     <!-- Jetty Embedded App Container --> 
     <!-- You only need this if you want to run the web app in the embedded jetty container using the RunApp class --> 
     <dependency> 
      <groupId>org.eclipse.jetty</groupId> 
      <artifactId>jetty-server</artifactId> 
      <version>9.2.0.v20140526</version> 
     </dependency> 

     <dependency> 
      <groupId>org.eclipse.jetty</groupId> 
      <artifactId>jetty-webapp</artifactId> 
      <version>9.2.0.v20140526</version> 
     </dependency> 

     <!-- Util --> 
     <dependency> 
      <groupId>commons-lang</groupId> 
      <artifactId>commons-lang</artifactId> 
      <version>2.4</version> 
     </dependency> 

     <dependency> 
      <groupId>com.google.code.gson</groupId> 
      <artifactId>gson</artifactId> 
      <version>2.2.4</version> 
     </dependency> 

     <!-- Groovy GMaven --> 
     <dependency> 
      <groupId>org.codehaus.gmaven</groupId> 
      <artifactId>gmaven-plugin</artifactId> 
      <version>1.4</version> 
     </dependency> 

    </dependencies> 

    <build> 
     <finalName>titan-web-example</finalName> 
     <plugins> 
      <plugin> 
       <groupId>org.apache.maven.plugins</groupId> 
       <artifactId>maven-war-plugin</artifactId> 
       <version>2.4</version> 
      </plugin> 

      <plugin> 
       <artifactId>maven-compiler-plugin</artifactId> 
       <configuration> 
        <source>1.7</source> 
        <target>1.7</target> 
       </configuration> 
      </plugin> 

      <plugin> 
       <groupId>org.codehaus.gmaven</groupId> 
       <artifactId>gmaven-plugin</artifactId> 
       <version>1.4</version> 
       <configuration> 
        <providerSelection>1.8</providerSelection> 
       </configuration> 
       <executions> 
        <execution> 
         <goals> 
          <goal>generateStubs</goal> 
          <goal>compile</goal> 
          <goal>generateTestStubs</goal> 
          <goal>testCompile</goal> 
         </goals> 
        </execution> 
       </executions> 
      </plugin> 

     </plugins> 
    </build> 

</project> 

것 같습니다,하지만 난 그것을 해결하는 방법을 모르겠어요.

+1

GMaven 플러그인을위한 적절한 커넥터가없는 것은 단지 M2E입니다. 그것에 대해 할 수있는 것은 아무것도 없습니다. M2E는 Maven 프로젝트의 백그라운드에서 자동으로 빌드되지 않지만 어쨌든 컵 케잌에만 장식됩니다 ... http://stackoverflow.com/a/27939648/1743880이 도움이 될지 모르겠지만 이것을 살펴보십시오. – Tunaki

답변

1

Eclipse에서 Maven 프로젝트를 처리하는 방법은 현재 m2e 플러그인을 통해 이루어집니다.

m2e 아니요은 아래의 Maven을 호출하지만 pom.xml 파일과 각 플러그인에 대해 플러그인과 마찬가지로 m2e 내부에서 동일하게 동작하도록 명시 적으로 작성된 호출 코드를 구문 분석합니다. 이것이 바로 "커넥터"입니다.

주어진 플러그인에 대해 커넥터를 사용할 수없는 경우 (m2e에서이 플러그인을 에뮬레이션 할 수 있음)이 오류가 표시됩니다. 불행히도 드문 플러그인이 드물지 않습니다.

m2e가 어쨌든 작업 할 수 있도록 프로젝트를 충분히 표시 할 수 있는지 조사한 다음 명령 줄에서 실제 빌드 만 수행하면되는지 조사해야합니다.

그런 귀찮은 프로젝트에 다른 무료 IDE를 사용할 수도 있습니다. IntelliJ는 거의 모든 pom.xml 파일에서 작동하며 Netbeans도 사용할 수 있다고합니다.

관련 문제