Grails-SpringSec依赖于不在Maven Central中的JAR? [英] Grails-SpringSec depends on JARs that aren't in Maven Central?

查看:203
本文介绍了Grails-SpringSec依赖于不在Maven Central中的JAR?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试配置一个Grails应用程序以使用最新的稳定 SpringSec-CAS插件和我的生活无法找到正确版本的SpringSec和我应该使用的插件。



我在Grails 2.3.6上。我应该在 BuildConfig.groovy 中包含哪些内容以获取最新的稳定版本?我有:

 插件{
compile:spring-security-core:2.0-RC2
编译:spring-security-cas:2.0-RC1

在运行 grails run-app 时出现以下错误:

  |错误解决错误获取依赖关系:以下工件无法解析:org.springframework.security:spring-security-web:jar:3.2.0.RC1,org.springframework.security:spring-security-cas:jar:3.2。 0.RC1:在mylocalartifactory_artifactory_libs-snapshots-local_(http:// mylocalartifactory / artifactory / libs-snapshots-local /)中找不到工件org.springframework.security:spring-security-web:jar:3.2.0.RC1(使用--stacktrace查看完整跟踪)
|错误解决错误获取依赖关系:以下工件无法解析:org.springframework.security:spring-security-web:jar:3.2.0.RC1,org.springframework.security:spring-security-cas:jar:3.2。 0.RC1:在mylocalartifactory_artifactory_libs-snapshots-local_(http:// mylocalartifactory / artifactory / libs-snapshots-local /)中找不到工件org.springframework.security:spring-security-web:jar:3.2.0.RC1(使用--stacktrace查看完整跟踪)
|错误解决错误获取依赖关系:以下工件无法解析:org.springframework.security:spring-security-web:jar:3.2.0.RC1,org.springframework.security:spring-security-cas:jar:3.2。 0.RC1:在mylocalartifactory_artifactory_libs-snapshots-local_(http:// mylocalartifactory / artifactory / libs-snapshots-local /)中找不到工件org.springframework.security:spring-security-web:jar:3.2.0.RC1(使用--stacktrace查看完整跟踪)
|错误以下工件无法解析:org.springframework.security:spring-security-web:jar:3.2.0.RC1,org.springframework.security:spring-security-cas:jar:3.2.0.RC1:Could没有在mylocalartifactory_artifactory_libs-snapshots-local_(http:// mylocalartifactory / artifactory / libs-snapshots-local /)中找到工件org.springframework.security:spring-security-web:jar:3.2.0.RC1

我认为我的储存库没有正确设置...?如何修改我的 BuildConfig.groovy 以从Maven Central中提取这些折扣?



运行Grails依赖关系报告:

  + --- org.grails.plugins:spring-security-core:2.0-RC2 
| >>>> org.springframework.security:spring-security-web:3.2.0.RC1
+ --- org.grails.plugins:spring-security-cas:2.0-RC1
| \ --- org.jasig.cas.client:cas-client-core:3.2.1
| >>>> org.springframework.security:spring-security-cas:3.2.0.RC1

仍然不是100%确定问题出在哪里。

解决方案

添加mavenRepo http://repo.spring.io/milestone/ 解决了我的依赖问题。


I am trying to configure a Grails app to use the latest stable SpringSec-CAS plugin and for the life of me cannot find the proper version of both SpringSec and the plugin I should be using.

I am on Grails 2.3.6. What should I include in BuildConfig.groovy to get the latest stable versions? I have:

plugins {
    compile  ":spring-security-core:2.0-RC2"
    compile  ":spring-security-cas:2.0-RC1"
}

When I specify SpringSec 2.0-RC2 and SpringSec-CAS 2.0-RC1 I get the following errors when running grails run-app:

| Error Resolve error obtaining dependencies: The following artifacts could not be resolved: org.springframework.security:spring-security-web:jar:3.2.0.RC1, org.springframework.security:spring-security-cas:jar:3.2.0.RC1: Could not find artifact org.springframework.security:spring-security-web:jar:3.2.0.RC1 in mylocalartifactory_artifactory_libs-snapshots-local_ (http://mylocalartifactory/artifactory/libs-snapshots-local/) (Use --stacktrace to see the full trace)
| Error Resolve error obtaining dependencies: The following artifacts could not be resolved: org.springframework.security:spring-security-web:jar:3.2.0.RC1, org.springframework.security:spring-security-cas:jar:3.2.0.RC1: Could not find artifact org.springframework.security:spring-security-web:jar:3.2.0.RC1 in mylocalartifactory_artifactory_libs-snapshots-local_ (http://mylocalartifactory/artifactory/libs-snapshots-local/) (Use --stacktrace to see the full trace)
| Error Resolve error obtaining dependencies: The following artifacts could not be resolved: org.springframework.security:spring-security-web:jar:3.2.0.RC1, org.springframework.security:spring-security-cas:jar:3.2.0.RC1: Could not find artifact org.springframework.security:spring-security-web:jar:3.2.0.RC1 in mylocalartifactory_artifactory_libs-snapshots-local_ (http://mylocalartifactory/artifactory/libs-snapshots-local/) (Use --stacktrace to see the full trace)
| Error The following artifacts could not be resolved: org.springframework.security:spring-security-web:jar:3.2.0.RC1, org.springframework.security:spring-security-cas:jar:3.2.0.RC1: Could not find artifact org.springframework.security:spring-security-web:jar:3.2.0.RC1 in mylocalartifactory_artifactory_libs-snapshots-local_ (http://mylocalartifactory/artifactory/libs-snapshots-local/)

I take it that I don't have my repositories set up correctly...? How can I modify my BuildConfig.groovy to pull these deps in from Maven Central?

Running Grails dependency report:

+--- org.grails.plugins:spring-security-core:2.0-RC2
|    >>>> org.springframework.security:spring-security-web:3.2.0.RC1
+--- org.grails.plugins:spring-security-cas:2.0-RC1
|    \--- org.jasig.cas.client:cas-client-core:3.2.1
|    >>>> org.springframework.security:spring-security-cas:3.2.0.RC1

Still not 100% sure what the problem is.

解决方案

Adding mavenRepo "http://repo.spring.io/milestone/" resolved the dependency issue for me.

这篇关于Grails-SpringSec依赖于不在Maven Central中的JAR?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆