spring-security-core插件的依赖性问题

时间:2013-10-05 10:02:13

标签: grails plugins spring-security

我正在尝试将spring-security-core插件安装到我的项目中,但似乎无法在任何存储库中找到插件文件。

我将此行添加到BuildConfig文件的插件部分:

    compile ':spring-security-core:2.0-RC2'

运行grails compile命令后,我遇到以下错误(缩短):

        ==== ebrRelease: tried

          http://repository.springsource.com/maven/bundles/release/org/springframework/security/spring-security-core/3.2.0.RC1/spring-security-core-3.2.0.RC1.pom

          -- artifact org.springframework.security#spring-security-core;3.2.0.RC1!spring-security-core.jar:

          http://repository.springsource.com/maven/bundles/release/org/springframework/security/spring-security-core/3.2.0.RC1/spring-security-core-3.2.0.RC1.jar

        ==== ebrExternal: tried

          http://repository.springsource.com/maven/bundles/external/org/springframework/security/spring-security-core/3.2.0.RC1/spring-security-core-3.2.0.RC1.pom

          -- artifact org.springframework.security#spring-security-core;3.2.0.RC1!spring-security-core.jar:

          http://repository.springsource.com/maven/bundles/external/org/springframework/security/spring-security-core/3.2.0.RC1/spring-security-core-3.2.0.RC1.jar

        ==== grailsCentral: tried

          http://grails.org/plugins/grails-spring-security-core/tags/RELEASE_3.2.0.RC1/spring-security-core-3.2.0.RC1.pom

          -- artifact org.springframework.security#spring-security-core;3.2.0.RC1!spring-security-core.jar:

          http://grails.org/plugins/grails-spring-security-core/tags/RELEASE_3.2.0.RC1/grails-spring-security-core-3.2.0.RC1.jar

        ==== mavenCentral: tried

          http://repo1.maven.org/maven2/org/springframework/security/spring-security-core/3.2.0.RC1/spring-security-core-3.2.0.RC1.pom

          -- artifact org.springframework.security#spring-security-core;3.2.0.RC1!spring-security-core.jar:

          http://repo1.maven.org/maven2/org/springframework/security/spring-security-core/3.2.0.RC1/spring-security-core-3.2.0.RC1.jar

                module not found: org.springframework.security#spring-security-web;3.2.0.RC1

        ==== grailsHome: tried

          C:\dev\springsource\grails-2.2.3\bin\../lib/org.springframework.security/spring-security-web/ivy-3.2.0.RC1.xml

          -- artifact org.springframework.security#spring-security-web;3.2.0.RC1!spring-security-web.jar:

          C:\dev\springsource\grails-2.2.3\bin\../lib/org.springframework.security/spring-security-web/jars/spring-security-web-3.2.0.RC1.jar

          C:\dev\springsource\grails-2.2.3\bin\../lib/org.springframework.security/spring-security-web/bundles/spring-security-web-3.2.0.RC1.jar

        ==== grailsHome: tried

          C:\dev\springsource\grails-2.2.3\bin\..\src\libs/spring-security-web-3.2.0.RC1.xml

          -- artifact org.springframework.security#spring-security-web;3.2.0.RC1!spring-security-web.jar:

          C:\dev\springsource\grails-2.2.3\bin\..\src\libs/spring-security-web-3.2.0.RC1.jar

        ==== grailsHome: tried

          C:\dev\springsource\grails-2.2.3\bin\..\dist/spring-security-web-3.2.0.RC1.xml

          -- artifact org.springframework.security#spring-security-web;3.2.0.RC1!spring-security-web.jar:

          C:\dev\springsource\grails-2.2.3\bin\..\dist/spring-security-web-3.2.0.RC1.jar

        ==== grailsHome: tried

          C:\dev\springsource\grails-2.2.3\bin\../plugins/spring-security-web-3.2.0.RC1.pom

          -- artifact org.springframework.security#spring-security-web;3.2.0.RC1!spring-security-web.jar:

          C:\dev\springsource\grails-2.2.3\bin\../plugins/spring-security-web-3.2.0.RC1.jar

        ==== ebrRelease: tried

          http://repository.springsource.com/maven/bundles/release/org/springframework/security/spring-security-web/3.2.0.RC1/spring-security-web-3.2.0.RC1.pom

          -- artifact org.springframework.security#spring-security-web;3.2.0.RC1!spring-security-web.jar:

          http://repository.springsource.com/maven/bundles/release/org/springframework/security/spring-security-web/3.2.0.RC1/spring-security-web-3.2.0.RC1.jar

        ==== ebrExternal: tried

          http://repository.springsource.com/maven/bundles/external/org/springframework/security/spring-security-web/3.2.0.RC1/spring-security-web-3.2.0.RC1.pom

          -- artifact org.springframework.security#spring-security-web;3.2.0.RC1!spring-security-web.jar:

          http://repository.springsource.com/maven/bundles/external/org/springframework/security/spring-security-web/3.2.0.RC1/spring-security-web-3.2.0.RC1.jar

        ==== grailsCentral: tried

          http://grails.org/plugins/grails-spring-security-web/tags/RELEASE_3.2.0.RC1/spring-security-web-3.2.0.RC1.pom

          -- artifact org.springframework.security#spring-security-web;3.2.0.RC1!spring-security-web.jar:

          http://grails.org/plugins/grails-spring-security-web/tags/RELEASE_3.2.0.RC1/grails-spring-security-web-3.2.0.RC1.jar

        ==== mavenCentral: tried

          http://repo1.maven.org/maven2/org/springframework/security/spring-security-web/3.2.0.RC1/spring-security-web-3.2.0.RC1.pom

          -- artifact org.springframework.security#spring-security-web;3.2.0.RC1!spring-security-web.jar:

          http://repo1.maven.org/maven2/org/springframework/security/spring-security-web/3.2.0.RC1/spring-security-web-3.2.0.RC1.jar

                ::::::::::::::::::::::::::::::::::::::::::::::

                ::          UNRESOLVED DEPENDENCIES         ::

                ::::::::::::::::::::::::::::::::::::::::::::::

                :: org.springframework.security#spring-security-core;3.2.0.RC1: not found

                :: org.springframework.security#spring-security-web;3.2.0.RC1: not found

                ::::::::::::::::::::::::::::::::::::::::::::::


| Error Failed to resolve dependencies (Set log level to 'warn' in BuildConfig.groovy for more information):

- org.springframework.security:spring-security-core:3.2.0.RC1
- org.springframework.security:spring-security-web:3.2.0.RC1

我还将ebr()存储库添加到存储库列表中。但这并没有改变任何事情。

如何解决此问题并正确下载插件?

2 个答案:

答案 0 :(得分:57)

您需要额外的存储库:

mavenRepo 'http://repo.spring.io/milestone'

见宣布:http://grails.1312388.n4.nabble.com/Spring-Security-2-0-RC-release-td4649905.html

答案 1 :(得分:0)

试试这个: 检查(最好是从同一个控制台)每个URL grails尝试下载

curl --verbose  http://grails.org/plugins/grails-spring-security-core/tags/RELEASE_2.0-RC2/spring-security-core-2.0-RC2.pom

就我而言,我检测到 http://grails.org 存储库已移至 https://repo.grails.org

HTTP/1.1 302 Found
Date: Fri, 06 Mar 2015 01:59:30 GMT
Content-Type: text/plain; charset=utf-8

内容长度:0 连接:保持活力 expires =周六,05-Mar-16 01:59:29 GMT;路径= /;域= .grails.org;仅Http 地点:https://repo.grails.org/grails/plugins-releases-local/org/grails/plugins/spring-security-core/2.0-RC2/spring-security-core-2.0-RC2.pom

祝你好运!