构建spring-crowd-security示例时出现maven错误

时间:2014-03-11 10:37:17

标签: java spring maven atlassian-crowd

我正在尝试从here构建示例应用程序。
我在运行mvn clean install -U时收到此错误消息:

[ERROR] Failed to execute goal on project crowd-spring-security-sample: Could not resolve dependencies for project test:crowd-spring-security-sample:jar:1.0-SNAPSHOT: Could not find artifact com.atlassian.crowd:crowd-integration-springsecurity:jar:2.5.1 in central (http://repo.maven.apache.org/maven2) -> [Help 1]

有人能指出我遗漏的东西吗? 这是我的pom:

<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/maven-v4_0_0.xsd">

    <modelVersion>4.0.0</modelVersion>

    <groupId>test</groupId>
    <artifactId>crowd-spring-security-sample</artifactId>
    <version>1.0-SNAPSHOT</version>

    <properties>
        <maven.compiler.source>1.6</maven.compiler.source>
        <maven.compiler.target>1.6</maven.compiler.target>
        <crowd.version>2.5.1</crowd.version>
        <spring.version>3.1.0.RELEASE</spring.version>
        <springsecurity.version>3.1.0.RELEASE</springsecurity.version>
    </properties>

    <dependencies>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.8.1</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-jdk14</artifactId>
            <version>1.5.8</version>
        </dependency>

        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>servlet-api</artifactId>
            <version>2.5</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>com.atlassian.crowd</groupId>
            <artifactId>crowd-integration-springsecurity</artifactId>
            <version>${crowd.version}</version>
            <scope>runtime</scope>
        </dependency>

        <!-- Crowd needs at runtime -->
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-context</artifactId>
            <version>${spring.version}</version>
            <scope>runtime</scope>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-core</artifactId>
            <version>${spring.version}</version>
            <scope>runtime</scope>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-beans</artifactId>
            <version>${spring.version}</version>
            <scope>runtime</scope>
        </dependency>

        <dependency>
            <groupId>org.springframework.security</groupId>
            <artifactId>spring-security-web</artifactId>
            <version>${springsecurity.version}</version>
            <scope>runtime</scope>
        </dependency>
        <dependency>
            <groupId>org.springframework.security</groupId>
            <artifactId>spring-security-config</artifactId>
            <version>${springsecurity.version}</version>
            <scope>runtime</scope>
        </dependency>

        <dependency>
            <groupId>org.springframework.security</groupId>
            <artifactId>spring-security-core</artifactId>
            <version>${springsecurity.version}</version>
        </dependency>
    </dependencies>
</project>

1 个答案:

答案 0 :(得分:1)

首先,您应该通过浏览search.maven.org来检查maven中央仓库中是否存在工件crowd-integration-springsecurity

工件不存在于maven中心,但您可以在此博客条目Atlassian Maven 2 Integration中配置atlassian maven存储库。