maven - 在 gradle 中,没有 pom 文件的 maven 工件从 jcenter 工作,但不是 mavenCentral
问题描述
我有一个使用 gradle 的 Java 项目,它使用了一些非常古老的依赖项。其中一个具有传递依赖,可以正常工作,jcenter()
但当我尝试迁移到mavenCentral()
. 该工件存在于 Maven Central 中,但没有 pom 文件。Gradle 给了我这样的错误:
> Could not resolve all files for configuration ':myproject:compileClasspath'.
> Could not find woodstox:wstx-asl:3.2.7.
Searched in the following locations:
- https://repo.maven.apache.org/maven2/woodstox/wstx-asl/3.2.7/wstx-asl-3.2.7.pom
我浏览 jcenter 存储库的任何尝试都会返回 403 Forbidden,因此我无法判断 pom 文件是否存在,但 Gradle 能够以某种方式使用jcenter()
.
这给我留下了几个问题:
- (非常旧的)maven 工件是否需要 pom 文件?
- gradle 如何访问https://jcenter.bintray.com/?
- 有什么方法可以查出 jcenter 工件是否有 pom 文件?
- 如果它没有 pom 文件,为什么 gradle 可以使用
jcenter()
但失败mavenCentral
?
提前感谢您的帮助!
解决方案
推荐阅读
- java - 如何在没有root的android应用程序中通过键盘上的坐标(不是视图元素)模拟触摸?
- python - 多次尝试...除了块语句引发另一个错误
- php - 合并数组中的数组并添加值
- python - Pandas 系列中的列出现在其余列上方的一行中
- javascript - 如何在 React 功能组件中使用 Props 将 Redux 对象添加为参数
- c# - Razor 页面路由 - 如何在下一页显示特定数据?
- python - 在给定列表上应用给定的数学表达式
- flutter - 使用 Flutter 在后台播放音频
- c# - 验证excel电子表格的每一行和每一列
- java - 如何在spring应用程序中动态修改application.properties文件?