DATAREDIS-419 - Move project build to Maven.

- Introduce Maven pom.xml.
- Moved Asciidoctor files to src/main/asciidoc.
- Moved notice.txt etc. to src/main/resources.
- Add logback.xml
- Update Makefile to use maven and pick build profiles.
- Update template.mf to pick up versions in pom.xml
- Add build matrix for spring versions to .travis.yml
- Use container based travis infrastructure.
- Update readme.

Original pull request: #167.
This commit is contained in:
Christoph Strobl
2016-01-28 19:31:21 +01:00
parent 1049bc3b5f
commit d72e8193b7
31 changed files with 312 additions and 187 deletions

1
.gitignore vendored
View File

@@ -4,7 +4,6 @@ bin
build
.gradle
.springBeans
pom.xml
*.iml
*.ipr
*.iws

View File

@@ -2,4 +2,16 @@ language: java
jdk:
- oraclejdk7
- oraclejdk8
script: make test
env:
matrix:
- PROFILE=ci
- PROFILE=spring41-next
- PROFILE=spring42
- PROFILE=spring42-next
- PROFILE=spring43-next
cache:
directories:
- $HOME/.m2
sudo: false
install: true
script: travis_wait make test SPRING_PROFILE=${PROFILE}

View File

@@ -13,6 +13,7 @@
# limitations under the License.
REDIS_VERSION:=2.8.19
SPRING_PROFILE?=ci
#######
# Redis
@@ -95,5 +96,5 @@ stop: redis-stop sentinel-stop
test:
$(MAKE) start
sleep 2
$(PWD)/gradlew clean build -DrunLongTests=true -S
mvn clean install -DrunLongTests=true -P$(SPRING_PROFILE)
$(MAKE) stop

View File

@@ -92,21 +92,22 @@ List<Person> peopleOnSecondFloor = listOps.range("users:floor:2", 0, -1);
# Building
Spring Data Redis uses Gradle as its build system. To build the system simply run:
Spring Data Redis uses Maven as its build system.
Running the tests requires you to have a RedisServer running at its default port. Using the `-D runLongTests=true` option executes additional Pub/Sub test.
gradlew
```bash
mvn clean install
```
from the project root folder. This will compile the sources, run the tests and create the artifacts.
You can alternatively use the provided `Makefile` which runs the build plus downloads and spins up the following environment:
To generate IDE-specific files, use
* 1 Single Node
* HA Redis (1 Master, 2 Slaves, 3 Sentinels).
* Redis Cluster (3 Masters, 1 Slave)
gradlew eclipse
or
gradlew idea
depending on your editor.
```bash
make test
```
# Contributing

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

View File

@@ -1,24 +0,0 @@
<html>
<body>
This document is the API specification for the Spring Data project.
<hr/>
<div id="overviewBody">
<!--
<p>
For further API reference and developer documentation, see the
<a href="http://static.springframework.org/spring/docs/2.0.x/reference/index.html" target="_top">Spring Framework reference documentation</a>.
That documentation contains more detailed, developer-targeted
descriptions, with conceptual overviews, definitions of terms,
workarounds, and working code examples.
</p>
-->
<p>
If you are interested in commercial training, consultancy and
support for the Spring Data Framework,
<a href="http://www.gopivotal.com/" target="_top">Pivotal Software, Inc.</a> provides
such commercial support.
</p>
</div>
</body>
</html>

View File

@@ -1,48 +0,0 @@
/* Spring-specific Javadoc style sheet rules */
#overviewBody {
}
.code {
border: 1px solid black;
background-color: #F4F4F4;
padding: 5px;
}
/* Vanilla Javadoc style sheet rules */
body {
font-family: Helvetica, Arial, sans-serif;
background-color: white;
font-size: 10pt;
}
td { font-size: 10pt; font-family: Helvetica, Arial, sans-serif }/* Javadoc style sheet */
/* Define colors, fonts and other style attributes here to override the defaults */
/* Page background color */
body { background-color: #FFFFFF }
/* Headings */
h1 { font-size: 145% }
/* Table colors */
.TableHeadingColor { background: #CCCCFF } /* Dark mauve */
.TableSubHeadingColor { background: #EEEEFF } /* Light mauve */
.TableRowColor { background: #FFFFFF } /* White */
/* Font used in left-hand frame lists */
.FrameTitleFont { font-size: 100%; font-family: Helvetica, Arial, sans-serif }
.FrameHeadingFont { font-size: 90%; font-family: Helvetica, Arial, sans-serif }
.FrameItemFont { font-size: 90%; font-family: Helvetica, Arial, sans-serif }
/* Navigation bar fonts and colors */
.NavBarCell1 { background-color:#EEEEFF;} /* Light mauve */
.NavBarCell1Rev { background-color:#00008B;} /* Dark Blue */
.NavBarFont1 { font-family: Arial, Helvetica, sans-serif; color:#000000;}
.NavBarFont1Rev { font-family: Arial, Helvetica, sans-serif; color:#FFFFFF;}
.NavBarCell2 { font-family: Arial, Helvetica, sans-serif; background-color:#FFFFFF;}
.NavBarCell3 { font-family: Arial, Helvetica, sans-serif; background-color:#FFFFFF;}

View File

@@ -1,79 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<book xmlns="http://docbook.org/ns/docbook" version="5.0"
xml:id="spring-data-keyvalue-reference"
xmlns:xi="http://www.w3.org/2001/XInclude"
xmlns:xlink="http://www.w3.org/1999/xlink">
<bookinfo>
<title>Spring Data Redis Reference Documentation</title>
<titleabbrev>Spring Data Redis ${version}</titleabbrev>
<releaseinfo>${version}</releaseinfo>
<productname>Spring Data Redis</productname>
<authorgroup>
<author>
<firstname>Costin</firstname>
<surname>Leau</surname>
<affiliation>SpringSource</affiliation>
</author>
<author>
<firstname>Jennifer</firstname>
<surname>Hickey</surname>
<affiliation>SpringSource</affiliation>
</author>
<author>
<firstname>Christoph</firstname>
<surname>Strobl</surname>
<affiliation>Pivotal Software, Inc.</affiliation>
</author>
<author>
<firstname>Thomas</firstname>
<surname>Darimont</surname>
<affiliation>Pivotal Software, Inc.</affiliation>
</author>
</authorgroup>
<legalnotice>
<para>
Copies of this document may be made for your own use and for distribution
to others, provided that you do not charge any fee for such copies and
further provided that each copy contains this Copyright Notice, whether
distributed in print or electronically.
</para>
</legalnotice>
<copyright xmlns:xi="http://www.w3.org/2001/XInclude">
<year>2011-2014</year>
<holder>The original authors.</holder>
</copyright>
</bookinfo>
<toc/>
<xi:include href="preface.xml"/>
<part id="introduction">
<title>Introduction</title>
<xi:include href="introduction/introduction.xml"/>
<xi:include href="introduction/why-sdr.xml"/>
<xi:include href="introduction/requirements.xml"/>
<xi:include href="introduction/getting-started.xml"/>
</part>
<part id="reference">
<title>Reference Documentation</title>
<xi:include href="reference/introduction.xml"/>
<xi:include href="reference/redis.xml"/>
</part>
<part id="appendixes">
<title>Appendixes</title>
<xi:include href="appendix/introduction.xml"/>
<xi:include href="appendix/appendix-schema.xml"/>
<xi:include href="appendix/appendix-command-reference.xml"/>
</part>
</book>

239
pom.xml Normal file
View File

@@ -0,0 +1,239 @@
<?xml version="1.0" encoding="UTF-8"?>
<project
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>
<groupId>org.springframework.data</groupId>
<artifactId>spring-data-redis</artifactId>
<version>1.5.3.BUILD-SNAPSHOT</version>
<name>Spring Data Redis</name>
<parent>
<groupId>org.springframework.data.build</groupId>
<artifactId>spring-data-parent</artifactId>
<version>1.6.3.BUILD-SNAPSHOT</version>
</parent>
<properties>
<dist.key>DATAREDIS</dist.key>
<jta>1.1</jta>
<beanutils>1.9.2</beanutils>
<xstream>1.4.4</xstream>
<pool>2.2</pool>
<lettuce>2.3.3</lettuce>
<jedis>2.6.2</jedis>
<srp>0.7</srp>
<jredis>06052013</jredis>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-pool2</artifactId>
<version>${pool}</version>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<!-- Spring -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-tx</artifactId>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-oxm</artifactId>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-aop</artifactId>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context-support</artifactId>
</dependency>
<!-- REDIS Drivers -->
<dependency>
<groupId>redis.clients</groupId>
<artifactId>jedis</artifactId>
<version>${jedis}</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.jredis</groupId>
<artifactId>jredis-core-api</artifactId>
<version>${jredis}</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.jredis</groupId>
<artifactId>jredis-core-ri</artifactId>
<version>${jredis}</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>com.github.spullara.redis</groupId>
<artifactId>client</artifactId>
<version>${srp}</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>com.lambdaworks</groupId>
<artifactId>lettuce</artifactId>
<version>${lettuce}</version>
<optional>true</optional>
</dependency>
<!--Mapper -->
<dependency>
<groupId>org.codehaus.jackson</groupId>
<artifactId>jackson-mapper-asl</artifactId>
<version>1.8.8</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
<version>${jackson}</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>${jackson}</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>commons-beanutils</groupId>
<artifactId>commons-beanutils</artifactId>
<version>${beanutils}</version>
<optional>true</optional>
</dependency>
<!-- Pool -->
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-pool2</artifactId>
<optional>true</optional>
</dependency>
<!-- Test -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jdbc</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>javax.transaction</groupId>
<artifactId>jta</artifactId>
<version>${jta}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>javax.annotation</groupId>
<artifactId>jsr250-api</artifactId>
<version>1.0</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.thoughtworks.xstream</groupId>
<artifactId>xstream</artifactId>
<version>${xstream}</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<includes>
<include>**/*Tests.java</include>
<include>**/*Test.java</include>
</includes>
<reuseForks>false</reuseForks>
<systemProperties>
<gemfire.disableShutdownHook>true</gemfire.disableShutdownHook>
<javax.net.ssl.keyStore>${basedir}/src/test/resources/trusted.keystore</javax.net.ssl.keyStore>
</systemProperties>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>wagon-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.asciidoctor</groupId>
<artifactId>asciidoctor-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>release</id>
<build>
<plugins>
<plugin>
<groupId>org.jfrog.buildinfo</groupId>
<artifactId>artifactory-maven-plugin</artifactId>
<inherited>false</inherited>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<repositories>
<repository>
<id>spring-libs-snapshot</id>
<url>https://repo.spring.io/libs-snapshot</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>spring-plugins-release</id>
<url>https://repo.spring.io/plugins-release</url>
</pluginRepository>
</pluginRepositories>
</project>

View File

@@ -1,7 +1,7 @@
[[appendix:schema]]
[appendix]
= Schema
:resourcesDir: ../../main/resources
:resourcesDir: ../../resources
== Core schema

View File

@@ -1,4 +1,3 @@
[[spring-data-keyvalue-reference]]
= Spring Data Redis
Costin Leau, Jennifer Hickey, Christoph Strobl, Thomas Darimont
:revnumber: {version}
@@ -7,14 +6,16 @@ Costin Leau, Jennifer Hickey, Christoph Strobl, Thomas Darimont
:toc-placement!:
:spring-data-commons-docs: https://raw.githubusercontent.com/spring-projects/spring-data-commons/master/src/main/asciidoc
(C) 2011-2014 The original authors.
(C) 2011-2016 The original authors.
NOTE: Copies of this document may be made for your own use and for distribution to others, provided that you do not charge any fee for such copies and further provided that each copy contains this Copyright Notice, whether distributed in print or electronically.
toc::[]
include::preface.adoc[]
:leveloffset: +1
include::new-features.adoc[]
:leveloffset: -1
[[introduction]]
= Introduction
@@ -42,3 +43,4 @@ include::reference/redis.adoc[]
include::appendix/introduction.adoc[]
include::appendix/appendix-schema.adoc[]
include::appendix/appendix-command-reference.adoc[]
:leveloffset: -1

View File

@@ -1,6 +1,8 @@
[[new-features]]
= New Features
New and noteworthy in the latest releases.
[[new-in-1-5-0]]
== New in Spring Data Redis 1.5

View File

@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%d %5p %40.40c:%4L - %m%n</pattern>
</encoder>
</appender>
<logger name="org.springframework.data" level="error" />
<root level="warn">
<appender-ref ref="console" />
</root>
</configuration>

View File

@@ -1,32 +1,36 @@
Bundle-SymbolicName: org.springframework.data.redis
Bundle-Name: Spring Data Redis Support
Bundle-Vendor: Pivotal Software, Inc.
Bundle-ManifestVersion: 2
Bundle-SymbolicName: org.springframework.data.redis
Bundle-Name: ${project.name}
Bundle-Vendor: Pivotal Software, Inc.
Bundle-Version: ${project.version}
Bundle-RequiredExecutionEnvironment: J2SE-1.6
Export-Template:
org.springframework.data.redis.*;version="${project.version}"
Import-Package:
sun.reflect;version="0";resolution:=optional
Import-Template:
org.springframework.beans.*;version="[4.0.9, 4.1.0)",
org.springframework.cache.*;version="[4.0.9, 4.1.0)",
org.springframework.context.*;version="[4.0.9, 4.1.0)",
org.springframework.core.*;version="[4.0.9, 4.1.0)",
org.springframework.dao.*;version="[4.0.9, 4.1.0)",
org.springframework.scheduling.*;resolution:="optional";version="[4.0.9, 4.1.0)",
org.springframework.scripting.*;resolution:="optional";version="[4.0.9, 4.1.0)",
org.springframework.util.*;version="[4.0.9, 4.1.0)",
org.springframework.aop.*;version="[4.0.9, 4.1.0)",
org.springframework.cglib.*;version="[4.0.9, 4.1.0)",
org.springframework.oxm.*;resolution:="optional";version="[4.0.9, 4.1.0)",
org.springframework.transaction.support.*;version="[4.0.9, 4.1.0)",
org.springframework.beans.*;version="${spring:[=.=.=.=,+1.1.0)}",
org.springframework.cache.*;version="${spring:[=.=.=.=,+1.1.0)}",
org.springframework.context.*;version="${spring:[=.=.=.=,+1.1.0)}",
org.springframework.core.*;version="${spring:[=.=.=.=,+1.1.0)}",
org.springframework.dao.*;version="${spring:[=.=.=.=,+1.1.0)}",
org.springframework.scheduling.*;resolution:="optional";version="${spring:[=.=.=.=,+1.1.0)}",
org.springframework.scripting.*;resolution:="optional";version="${spring:[=.=.=.=,+1.1.0)}",
org.springframework.util.*;version="${spring:[=.=.=.=,+1.1.0)}",
org.springframework.aop.*;version="${spring:[=.=.=.=,+1.1.0)}",
org.springframework.cglib.*;version="${spring:[=.=.=.=,+1.1.0)}",
org.springframework.oxm.*;resolution:="optional";version="${spring:[=.=.=.=,+1.1.0)}",
org.springframework.transaction.support.*;version="${spring:[=.=.=.=,+1.1.0)}",
org.aopalliance.*;version="[1.0.0, 2.0.0)";resolution:=optional,
org.apache.commons.logging.*;version="[1.1.1, 2.0.0)",
org.w3c.dom.*;version="0",
javax.xml.transform.*;resolution:="optional";version="0",
org.jredis.*;resolution:="optional";version="[1.0.0, 2.0.0)",
redis.clients.*;resolution:="optional";version="[2.6.2, 3.0.0)",
org.apache.commons.pool2.*;resolution:="optional";version="[1.0, 2.2)",
redis.clients.*;resolution:="optional";version="${jedis}",
org.apache.commons.pool2.*;resolution:="optional";version="${pool}",
org.codehaus.jackson.*;resolution:="optional";version="[1.6, 2.0.0)",
com.fasterxml.jackson.*;resolution:="optional";version="[2.0.0, 3.0.0)",
org.apache.commons.beanutils.*;resolution:="optional";version=1.8.5,
com.fasterxml.jackson.*;resolution:="optional";version="${jackson}",
org.apache.commons.beanutils.*;resolution:="optional";version="${beanutils}",
redis.*;resolution:="optional";version="[0.2, 1.0)",
com.google.common.*;resolution:="optional";version="[11.0.0, 20.0.0)",
com.lambdaworks.*;resolution:="optional";version="[2.2.0, 3.0.0)",