我在代理后面工作,我面临SSL问题。因此,我无法正确地使用HTTPS,因此在maven的settings.xml文件中,我将存储库设置为"http://repo1.maven.org/maven2",即HTTP,如下所示:
<settings>
<activeProfiles>
<activeProfile>securecentral</activeProfile>
</activeProfiles>
<profiles>
<profile>
<id>securecentral</id>
<repositories>
<repository>
<id>central</id>
<url>http://repo1.maven.org/maven2</url>
<releases>
<enabled>true</enabled>
</releases>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>central</id>
<url>http://repo1.maven.org/maven2</url>
<releases>
<enabled>true</enabled>
</releases>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
</settings>它适用于某些依赖项,但当我向pom.xml中添加一个依赖项(特别是这个依赖项)时:
<dependency>
<groupId>com.twelvemonkeys.imageio</groupId>
<artifactId>imageio-tiff</artifactId>
<version>3.3.2</version>
</dependency>Eclipse无法下载它(我不知道这个问题是来自代理、存储库本身还是其他问题)
我的问题是:是否将存储库设置为"http://repo1.maven.org/maven2“限制插件、库或我可以使用普通存储库"https://mvnrepository.com/”下载的任何东西的数量,或者完全相同,没有任何限制或区别,除了第一个是通过HTTP而不是HTTPS?
发布于 2017-03-04 15:14:35
我希望您理解,这两个库都是存储库,包括开发人员通过distributionManagement上传的工件。
它们在到达的端点方面是不一样的。
首选的是maven central - http://repo1.maven.org/maven2,它可以查看https://search.maven.org/。
有一个有用的链接,让消费者开始使用它。- Cental.sonatype.org/pages/consumers和共享的代码似乎非常有可能遵循(消费者- Apache Maven)
https://stackoverflow.com/questions/42596137
复制相似问题