Announcement Announcement Module
Collapse
No announcement yet.
Spring Data Maven issues with Nexus Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Spring Data Maven issues with Nexus

    So whenever we get a new person at work, they checkout from our Git repo and they can't build because they can never get the Spring Data jars. Now we have a nexus company repo, and none of the Spring Data jars get placed there even if we try a mvn deploy. In the pom files we have all the necessary Spring repositories, so even if it wasn't in our nexus repo, it should have then gone up to the Spring repositories to get the Spring Data jars.

    Why isn't that working?

    Thanks

    Mark

    example poms

    Code:
    <?xml version="1.0" encoding="UTF-8" standalone="no"?>
    <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>com.ourcompany</groupId>
        <artifactId>data-integration-server</artifactId>
        <packaging>jar</packaging>
        <version>0.1.0</version>
        <name>data-integration-server</name>
        <properties>
            <aspectj.version>1.6.12</aspectj.version>
            <jackson.version>1.9.3</jackson.version>
            <junit.version>4.8.2</junit.version>
            <jodatime.version>1.6</jodatime.version>
            <log4j.version>1.2.16</log4j.version>
            <mongo-driver.version>2.8.0</mongo-driver.version>
            <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
            <slf4j.version>1.6.1</slf4j.version>
            <spring.version>3.1.0.RELEASE</spring.version>
            <spring.amqp.version>1.1.1.RELEASE</spring.amqp.version>
            <spring-data-commons.version>1.3.1.RELEASE</spring-data-commons.version>
            <spring-data-mongodb.version>1.1.0.M1</spring-data-mongodb.version>
            <spring-security.version>3.1.0.RELEASE</spring-security.version>
            <spring-integration.version>2.1.3.RELEASE</spring-integration.version>
        </properties>
        <repositories>
            <repository>
                <id>spring-maven-release</id>
                <name>Spring Maven Release Repository</name>
                <url>http://maven.springframework.org/release</url>
            </repository>
            <repository>
                <id>spring-release</id>
                <name>Spring Maven Release Repository</name>
                <url>http://repo.springsource.org/libs-release</url>
            </repository>
            <repository>
                <id>repository.springsource.milestone</id>
                <name>SpringSource Milestone Repository</name>
                <url>http://repo.springsource.org/milestone</url>
            </repository>
            <repository>
                <id>spring-libs-milestone</id>
                <url>http://repo.springsource.org/libs-milestone</url>
                <snapshots>
                    <enabled>false</enabled>
                </snapshots>
            </repository>
    
        </repositories>
        <pluginRepositories>
            <pluginRepository>
                <id>spring-maven-release</id>
                <name>Spring Maven Release Repository</name>
                <url>http://maven.springframework.org/release</url>
            </pluginRepository>
        </pluginRepositories>
        <dependencies>
            <dependency>
                <groupId>org.aspectj</groupId>
                <artifactId>aspectjrt</artifactId>
                <version>${aspectj.version}</version>
            </dependency>
            <dependency>
                <groupId>org.aspectj</groupId>
                <artifactId>aspectjweaver</artifactId>
                <version>${aspectj.version}</version>
            </dependency>
    
            <!-- Core Spring dependencies -->
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-core</artifactId>
                <version>${spring.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>commons-logging</groupId>
                        <artifactId>commons-logging</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-test</artifactId>
                <version>${spring.version}</version>
                <scope>test</scope>
                <exclusions>
                    <exclusion>
                        <groupId>commons-logging</groupId>
                        <artifactId>commons-logging</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-context</artifactId>
                <version>${spring.version}</version>
            </dependency>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-aop</artifactId>
                <version>${spring.version}</version>
            </dependency>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-aspects</artifactId>
                <version>${spring.version}</version>
            </dependency>
    
            <!--Some odd requirement now-->
            <dependency>
              <groupId>javax.persistence</groupId>
              <artifactId>persistence-api</artifactId>
              <version>1.0</version>
              <optional>true</optional>
            </dependency>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-tx</artifactId>
                <version>${spring.version}</version>
            </dependency>
    
            <!-- Spring Integration jars-->
            <dependency>
               <groupId>org.springframework.integration</groupId>
               <artifactId>spring-integration-amqp</artifactId>
               <version>${spring-integration.version}</version>
            </dependency>
    
            <dependency>
                <groupId>org.springframework.data</groupId>
                <artifactId>spring-data-commons-core</artifactId>
                <version>${spring-data-commons.version}</version>
            </dependency>
    
            <!-- Spring Data MongoDB -->
            <dependency>
                <groupId>org.springframework.data</groupId>
                <artifactId>spring-data-mongodb-log4j</artifactId>
                <version>1.0.2.RELEASE</version>
            </dependency>
            <dependency>
                <groupId>org.springframework.data</groupId>
                <artifactId>spring-data-mongodb</artifactId>
                <version>${spring-data-mongodb.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>org.springframework.data</groupId>
                        <artifactId>spring-data-commons-core</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
    
            <!--MongoDB dependencies -->
            <dependency>
                <groupId>org.mongodb</groupId>
                <artifactId>mongo-java-driver</artifactId>
                <version>${mongo-driver.version}</version>
            </dependency>
        </dependencies>
        <build>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>2.3.2</version>
                    <configuration>
                        <source>1.7</source>
                        <target>1.7</target>
                        <encoding>UTF-8</encoding>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>2.8</version>
                    <configuration>
                        <printSummary>false</printSummary>
                        <redirectTestOutputToFile>true</redirectTestOutputToFile>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>2.4</version>
                </plugin>
                <!--plugin>
                    <artifactId>maven-assembly-plugin</artifactId>
                    <configuration>
                        <descriptorRefs>
                            <descriptorRef>jar-with-dependencies</descriptorRef>
                        </descriptorRefs>
                    </configuration>
                    <executions>
                        <execution>
                            <id>make-my-jar-with-dependencies</id>
                            <phase>package</phase>
                            <goals>
                                <goal>single</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin-->
            </plugins>
        </build>
        <distributionManagement>
            <repository>
                <id>releases</id>
                <name>Release Repository</name>
                <url>http://nexus.z4poker.net:8081/nexus/content/repositories/releases/</url>
            </repository>
            <snapshotRepository>
                <id>snapshots</id>
                <name>Snapshot Repository</name>
                <url>http://nexus.z4poker.net:8081/nexus/content/repositories/snapshots/</url>
            </snapshotRepository>
        </distributionManagement>
    </project>
Working...
X