【问题标题】:Problem downloading MMLSpark library as a Maven dependency将 MMLSpark 库作为 Maven 依赖项下载时出现问题
【发布时间】:2021-09-09 02:53:33
【问题描述】:

我对使用 Maven 完全陌生。我正在尝试使用屏幕截图的命令从微软的 MMLSPARK 库中下载一个 jar 文件:

我收到此错误...不知道是什么问题。

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-dependency-plugin:2.8:get (default-cli) on project standalone-pom: Couldn't download artifact: Missing:
[ERROR] ----------
[ERROR] 1) com.microsoft.ml.spark:mmlspark_2.11:jar:1.0.0-rc1
[ERROR]
[ERROR]   Try downloading the file manually from the project website.
[ERROR]
[ERROR]   Then, install it using the command:
[ERROR]       mvn install:install-file -DgroupId=com.microsoft.ml.spark -DartifactId=mmlspark_2.11 -Dversion=1.0.0-rc1 -Dpackaging=jar -Dfile=/path/to/file
[ERROR]
[ERROR]   Alternatively, if you host your own repository you can deploy the file there:
[ERROR]       mvn deploy:deploy-file -DgroupId=com.microsoft.ml.spark -DartifactId=mmlspark_2.11 -Dversion=1.0.0-rc1 -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
[ERROR]
[ERROR]   Path to dependency:
[ERROR]         1) org.apache.maven.plugins:maven-downloader-plugin:jar:1.0
[ERROR]         2) com.microsoft.ml.spark:mmlspark_2.11:jar:1.0.0-rc1
[ERROR]
[ERROR] ----------
[ERROR] 1 required artifact is missing.
[ERROR]
[ERROR] for artifact:
[ERROR]   org.apache.maven.plugins:maven-downloader-plugin:jar:1.0
[ERROR]
[ERROR] from the specified remote repositories:

【问题讨论】:

  • 请勿发布代码、数据、错误消息等的图片 - 将文本复制或输入到问题中。 How to Ask

标签: java maven jar


【解决方案1】:

除非你有一个奇怪的 maven 配置,否则截图的命令是有效的!我刚刚执行了它。结果是在当前工作目录中得到一个名为 mmlspark_2.11-1.0.0-rc1.jar 的 jar。

另外,请确保您准确输入:

mvn dependency:get -DremoteRepositories="https://mmlspark.azureedge.net/maven" -Dartifact="com.microsoft.ml.spark:mmlspark_2.11:1.0.0-rc1" -Ddest=.

(复制粘贴!)

如果您继续遇到问题,请在命令中添加 -X 标志(调试模式),它将打印有关幕后情况的更多信息...

【讨论】:

  • 嗨。问题是屏幕截图来自github问题,有人能够成功运行命令。我无法做到。在那个 github 问题中,另一个用户遇到了和我一样的错误。
猜你喜欢
  • 2021-12-08
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2020-04-22
  • 1970-01-01
  • 1970-01-01
  • 2013-12-01
相关资源
最近更新 更多