如何在maven中添加orientDB存储库?

时间:2014-01-08 16:47:17

标签: maven orientdb

我正在尝试按照这些instructions在maven中添加orientdb repo。我的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/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <groupId>orient-test</groupId>
  <artifactId>orientdb</artifactId>
  <version>0.0.1-SNAPSHOT</version>
  <licenses>
        <license>
            <name>The Apache Software License, Version 2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
                <distribution>repo</distribution>
                  </license>
  </licenses>
  <build>
    <sourceDirectory>src</sourceDirectory>
    <plugins>
      <plugin>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>3.1</version>
        <configuration>
          <source>1.7</source>
          <target>1.7</target>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.felix</groupId>
        <artifactId>maven-bundle-plugin</artifactId>
        <version>2.3.6</version>
        <extensions>true</extensions>
      </plugin>
    </plugins>
  </build>
  <dependencies>
    <dependency>
    <groupId>com.orientechnologies</groupId>
    <artifactId>orient-commons</artifactId>
    <version>1.6.1-SNAPSHOT</version>
    <type>bundle</type>
  </dependency>
  <dependency>
    <groupId>com.orientechnologies</groupId>
    <artifactId>orientdb-core</artifactId>
    <version>1.6.1-SNAPSHOT</version>
    <type>bundle</type>
  </dependency>
  <dependency>
    <groupId>com.tinkerpop.blueprints</groupId>
    <artifactId>blueprints-orient-graph</artifactId>
    <version>2.5.0-SNAPSHOT</version>
    <type>bundle</type>
  </dependency>
  <repository>
    <id>sonatype-nexus-releases</id>
    <name>Sonatype Nexus Snapshots</name>
    <url>https://oss.sonatype.org/content/repositories/snapshots</url>
  </repository>
  </dependencies>
</project>

但我一直收到这些错误:

  

缺少神器   com.orientechnologies:东方公地:罐:1.6.1-SNAPSHOT

     

缺少神器   com.orientechnologies:orientdb核:罐:1.6.1-SNAPSHOT

     

缺少神器   com.tinkerpop.blueprints:蓝图 - 定位 - 图:罐:2.5.0-SNAPSHOT

也用红色加下划线,但没有错误信息。

4 个答案:

答案 0 :(得分:1)

请勿使用旧快照,只需将“1.6.1-SNAPSHOT”替换为“1.6.3”

答案 1 :(得分:0)

我通过添加1.6.3版本的orient-commons和oriented-core来解决我的问题。对于blueprints-orient-graph,您应该添加以下代码片段:

<repositories>
    <repository>
        <id>sonatype-nexus-snapshots</id>
        <name>Sonatype Nexus Snapshots</name>
        <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        <releases>
            <enabled>false</enabled>
        </releases>
        <snapshots>
            <enabled>true</enabled>
        </snapshots>
    </repository>
</repositories>

而不是原始问题中的内容

答案 2 :(得分:0)

答案 3 :(得分:0)

我刚刚在 pom.xml 文件&amp;中添加了以下依赖项。一切都像魅力一样。

<dependency>
    <groupId>com.orientechnologies</groupId>
    <artifactId>orientdb-graphdb</artifactId>
    <version>2.0.5</version>
</dependency>