【问题标题】:springfox 2.2.3 snapshot dependencies adding failed because of missing nexus-maven-repository-index.propertiesspringfox 2.2.3 快照依赖项添加失败,因为缺少 nexus-maven-repository-index.properties
【发布时间】:2015-11-11 13:30:13
【问题描述】:

我在 IDEA 14 中使用带有 gradle 的 springfox 2.2.3 快照版本设置我的项目。我遵循指令2.1.1. Gradle Snapshot。我因无法索引 maven 存储库并在 IDEA 的日志中看到异常而失败:

WARN -      #org.jetbrains.idea.maven - Failed to update Maven indices for: [com.intellij.util.CachedValueImpl@a1d13c] http://oss.jfrog.org/simple/oss-snapshot-local/io/springfox 

org.jetbrains.idea.maven.server.MavenServerIndexerException:java.lang.RuntimeException:java.io.FileNotFoundException:资源nexus-maven-repository-index.properties 不存在

我尝试了两个存储库,但都失败了:

有人知道如何解决这个问题吗?

我尝试手动下载依赖项并将它们放在我的本地 .m2 目录中,并在 gradle mavenLocal() 而不是 maven {url ...} 中进行设置,但我的尝试失败了,IDEA 对 Gradle 刷新操作发出警告:

Warning:<i><b>project ':data-service': Web Facets/Artifacts will not be configured</b>
Details: org.gradle.api.artifacts.ResolveException: Could not resolve all dependencies for configuration ':data-service:runtime'.
Caused by: org.gradle.internal.resolve.ModuleVersionNotFoundException: Could not find io.springfox:springfox-swagger2:2.2.3-SNAPSHOT.
Required by:
parseq:data-service:2.4.0 alpha</i>

现在我认为也应该为 springfox 包手动添加传递依赖。但它看起来很丑,我认为我不应该这样。

有人知道我该怎么做吗?

【问题讨论】:

    标签: intellij-idea gradle swagger-2.0 springfox ojo


    【解决方案1】:

    我发现依赖项下载存在问题: * 当我从公司网络工作时,我有 SSL 证书问题 * 最初我将maven { url 'http://oss.jfrog.org/artifactory/oss-snapshot-local/' } 添加到buildscript {...} 部分,我将其更改为repositories {...} 并修复了问题 * 我也将我的 gradle 更新到 2.4 版本(但没有帮助)

    现在我的起始问题已解决。

    【讨论】:

      猜你喜欢
      • 2017-12-19
      • 1970-01-01
      • 2016-03-10
      • 2018-10-12
      • 2019-04-09
      • 2021-02-16
      • 2014-06-10
      • 2012-12-15
      • 1970-01-01
      相关资源
      最近更新 更多