gpt4 book ai didi

java - 无法为 spark-cloudant 加载 Maven 依赖项。获取丢失的 Artifact cloudant-libs :spark-cloudant:jar:2. 0.0-s_2.11

转载 作者:行者123 更新时间:2023-11-30 08:30:56 25 4
gpt4 key购买 nike

在 Java 中,我在下面添加了 maven 依赖项,

<dependency>
<groupId>cloudant-labs</groupId>
<artifactId>spark-cloudant</artifactId>
<version>2.0.0-s_2.11</version>
</dependency>

但即使在显示以下错误的 pom.xml 文件中也没有加载包,

Missing artifact cloudant-labs:spark-cloudant:jar:2.0.0-s_2.11

谁能帮我问一下为什么会导致问题?

我可以添加另一个 Maven 依赖项,但特别是这不起作用..

最佳答案

它不在官方 Maven 存储库中。 ( http://search.maven.org/#search%7Cga%7C1%7Cspark-cloudant )

但是当你检查:https://mvnrepository.com/artifact/cloudant-labs/spark-cloudant/2.0.0-s_2.11有注意事项:

Note: this artifact it located at Spark Packages repository(https://dl.bintray.com/spark-packages/maven/)

因此您需要将以下内容添加到您的pom.xml:

<repositories>
<repository>
<id>bintray</id>
<name>bintray.com</name>
<url>https://dl.bintray.com/spark-packages/maven/</url>
</repository>
</repositories>

编辑:

根据 https://spark.apache.org/news/new-repository-service.html

Bintray, the original repository service used for https://spark-packages.org/, is in its sunset process, and will no longer be available from May 1st. To consume artifacts from the new repository service, please replace “dl.bintray.com/spark-packages/maven” with “repos.spark-packages.org” in the Maven pom files or sbt build files in your repositories.

所以这应该可行:

<repositories>
<repository>
<id>bintray</id>
<name>bintray.com</name>
<url>https://repos.spark-packages.org</url>
</repository>
</repositories>

关于java - 无法为 spark-cloudant 加载 Maven 依赖项。获取丢失的 Artifact cloudant-libs :spark-cloudant:jar:2. 0.0-s_2.11,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40917896/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com