简体   繁体   English

Scala Casbah MongoDB驱动程序-Maven错误

[英]Scala Casbah MongoDB driver - Maven error

What is the correct way to set up Casbah MongoDB driver in Maven? 在Maven中设置Casbah MongoDB驱动程序的正确方法是什么? I have the following error when I tried to run Maven build, I get the following error: 尝试运行Maven构建时出现以下错误,出现以下错误:

[ERROR] The following artifacts could not be resolved: org.mongodb:casbah_2.10:jar:2.5.1, com.novus:salat-core:jar:1.9.2: Failure to find org.mongodb:casbah_2.10:jar:2.5.1 in https://oss.sonatype.org/content/repositories/releases/ was cached in the local repository, resolution will not be reattempted until the update interval of oss-sonatype-releases has elapsed or updates are forced -> [Help 1]

I have added the maven dependency as well and the repo location, but looking at the following URL from where Maven is supposed to fetch the jar file, it seems not to be there! 我还添加了Maven依赖项和存储库位置,但从Maven应该从中获取jar文件的位置看以下URL,似乎不存在!

https://oss.sonatype.org/content/repositories/releases/org/mongodb/casbah_2.10/2.5.1/ https://oss.sonatype.org/content/repositories/releases/org/mongodb/casbah_2.10/2.5.1/

What is the correct way to set this up. 进行此设置的正确方法是什么。 It is damn frustrating to have so many repositories without any jar files. 有这么多没有任何jar文件的存储库真是令人沮丧。

The casbah main project has the pom file which describes all the dependencies. casbah主项目具有pom文件,该文件描述了所有依赖项。 As you can see here: https://oss.sonatype.org/content/repositories/releases/org/mongodb/casbah_2.10/2.5.1/casbah_2.10-2.5.1.pom 如您所见: https : //oss.sonatype.org/content/repositories/releases/org/mongodb/casbah_2.10/2.5.1/casbah_2.10-2.5.1.pom

Typically, your build tool should be able to read the pom and fetch the dependencies. 通常,您的构建工具应该能够读取pom并获取依赖项。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM