java - open-saml 3 缺少工件
问题描述
尝试在 Eclipse 中构建一个小型示例项目(尝试了 Eclipse 的火星和氧气释放)。使用 Java 1.8。当我添加 opensaml 依赖项时,它在 opensaml-saml-impl 上失败,指示:
Missing artifact org.apache.commons:commons-collections:jar:3.2.1
Missing artifact org.apache.commons:commons-lang:jar:2.6
Missing artifact org.apache.jakarta:oro:jar:2.0.8
带有以下 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>testSAML2</groupId>
<artifactId>test.test.saml</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>abc</name>
<build>
<sourceDirectory>src</sourceDirectory>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.7.0</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
</plugins>
</build>
<properties>
<opensaml.version>3.3.0</opensaml.version>
</properties>
<dependencies>
<dependency>
<groupId>org.opensaml</groupId>
<artifactId>opensaml-core</artifactId>
<version>${opensaml.version}</version>
</dependency>
<dependency>
<groupId>org.opensaml</groupId>
<artifactId>opensaml-saml-api</artifactId>
<version>${opensaml.version}</version>
</dependency>
<dependency>
<groupId>org.opensaml</groupId>
<artifactId>opensaml-saml-impl</artifactId>
<version>${opensaml.version}</version>
</dependency>
<dependency>
<groupId>org.opensaml</groupId>
<artifactId>opensaml-messaging-api</artifactId>
<version>${opensaml.version}</version>
</dependency>
<dependency>
<groupId>org.opensaml</groupId>
<artifactId>opensaml-messaging-impl</artifactId>
<version>${opensaml.version}</version>
</dependency>
<dependency>
<groupId>org.opensaml</groupId>
<artifactId>opensaml-soap-api</artifactId>
<version>${opensaml.version}</version>
</dependency>
<dependency>
<groupId>org.opensaml</groupId>
<artifactId>opensaml-soap-impl</artifactId>
<version>${opensaml.version}</version>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-core</artifactId>
<version>1.1.7</version>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
<version>1.1.7</version>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>3.1.0</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
<version>1.2</version>
</dependency>
</dependencies>
</project>
我试图在底部添加一个存储库但没有改变:
<repositories>
<repository>
<id>shib-release</id>
<url>https://build.shibboleth.net/nexus/content/repositories/releases</url>
</repository>
</repositories>
任何人有任何想法为什么?我尝试“更新项目...”,尝试删除/添加为 maven 项目,尝试了一个空的新项目,尝试安装氧气作为新的 ide,但仍然遇到同样的问题。
解决方案
通过一系列步骤解决。最终,我认为最后一步是解决问题的主要步骤(maven build)。这是系列:
- 删除整个本地存储库(您的 .m2/repository)
- 删除了对旧 JVM 的所有引用
- 重启日食
- 多次重置为java 1.8界面,当我选择Maven | 时,maven中的某些东西认为它的JVM1.5 | '更新项目...'
- 根据容器“Maven 依赖项”引用非现有库运行Maven 构建- STS Mike Salleses 回答
- 运行方式 | Maven 构建 | 目标'干净安装-U' | 跑
maven 构建是我从未见过的新技术。它基本上构建了包括 maven pulls 的项目,您可以以日志样式格式查看失败的详细信息。
maven构建最终强制下载所有jar并编译。此时,其余的测试项目都使用了干净的构建。
推荐阅读
- php - Laravel 重置密码链接导致 404 页面
- python - 使用 Python 共享内存的分段错误
- r - 如何使用 dplyr::relocate 一步重定位多个列?
- ios - 将 Xcode 与 2 个 Firebase 项目一起使用的最佳方式 - 2 GoogleService-Info.plist
- google-bigquery - BigQuery - 具有不同 WHERE 参数的嵌套查询?
- python - 每次我运行 pyinstaller 可执行文件时,pyngrok 都会下载 ngrok。我怎样才能让它只下载一次ngrok?
- php - 打印/保存完整的 Laravel Artisan 命令输出(来自调试行的大数组)到文件
- php - fpdf - 如何将数据分成 3 列?
- java - 正则表达式查找数字后跟任何字符(逗号、点、感叹号)(Java 有
- python - 如何移动第二个x轴的位置?