Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit eb78711

Browse files
committed
Add CI stage testing against valkey.
Closes #2923
1 parent bca4021 commit eb78711

File tree

7 files changed

+78
-18
lines changed

7 files changed

+78
-18
lines changed

‎Jenkinsfile‎

Lines changed: 42 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ pipeline {
3333

3434
steps {
3535
script {
36-
def image = docker.build("springci/spring-data-with-redis-6.2:${p['java.main.tag']}", "--build-arg BASE=${p['docker.java.main.image']} --build-arg REDIS=${p['docker.redis.6.version']} -f ci/openjdk17-redis-6.2/Dockerfile .")
36+
def image = docker.build("springci/spring-data-with-redis-6.2:${p['java.main.tag']}", "--build-arg BASE=${p['docker.java.main.image']} --build-arg VERSION=${p['docker.redis.6.version']} -f ci/openjdk17-redis-6.2/Dockerfile .")
3737
docker.withRegistry(p['docker.registry'], p['docker.credentials']) {
3838
image.push()
3939
}
@@ -53,7 +53,27 @@ pipeline {
5353

5454
steps {
5555
script {
56-
def image = docker.build("springci/spring-data-with-redis-7.2:${p['java.main.tag']}", "--build-arg BASE=${p['docker.java.main.image']} --build-arg REDIS=${p['docker.redis.7.version']} -f ci/openjdk17-redis-7.2/Dockerfile .")
56+
def image = docker.build("springci/spring-data-with-redis-7.2:${p['java.main.tag']}", "--build-arg BASE=${p['docker.java.main.image']} --build-arg VERSION=${p['docker.redis.7.version']} -f ci/openjdk17-redis-7.2/Dockerfile .")
57+
docker.withRegistry(p['docker.registry'], p['docker.credentials']) {
58+
image.push()
59+
}
60+
}
61+
}
62+
}
63+
stage('Publish JDK 17 + Valkey 7.2 Docker Image') {
64+
when {
65+
anyOf {
66+
changeset "ci/openjdk17-valkey-7.2/Dockerfile"
67+
changeset "Makefile"
68+
changeset "ci/pipeline.properties"
69+
}
70+
}
71+
agent { label 'data' }
72+
options { timeout(time: 20, unit: 'MINUTES') }
73+
74+
steps {
75+
script {
76+
def image = docker.build("springci/spring-data-with-valkey-7.2:${p['java.main.tag']}", "--build-arg BASE=${p['docker.java.main.image']} --build-arg VERSION=${p['docker.redis.7.version']} -f ci/openjdk17-redis-7.2/Dockerfile .")
5777
docker.withRegistry(p['docker.registry'], p['docker.credentials']) {
5878
image.push()
5979
}
@@ -73,7 +93,7 @@ pipeline {
7393

7494
steps {
7595
script {
76-
def image = docker.build("springci/spring-data-with-redis-6.2:${p['java.next.tag']}", "--build-arg BASE=${p['docker.java.next.image']} --build-arg REDIS=${p['docker.redis.6.version']} -f ci/openjdk21-redis-6.2/Dockerfile .")
96+
def image = docker.build("springci/spring-data-with-redis-6.2:${p['java.next.tag']}", "--build-arg BASE=${p['docker.java.next.image']} --build-arg VERSION=${p['docker.redis.6.version']} -f ci/openjdk21-redis-6.2/Dockerfile .")
7797
docker.withRegistry(p['docker.registry'], p['docker.credentials']) {
7898
image.push()
7999
}
@@ -172,6 +192,25 @@ pipeline {
172192
}
173193
}
174194
}
195+
196+
stage("test: Valkey 7") {
197+
agent {
198+
label 'data'
199+
}
200+
options { timeout(time: 30, unit: 'MINUTES') }
201+
environment {
202+
ARTIFACTORY = credentials("${p['artifactory.credentials']}")
203+
DEVELOCITY_CACHE = credentials("${p['develocity.cache.credentials']}")
204+
DEVELOCITY_ACCESS_KEY = credentials("${p['develocity.access-key']}")
205+
}
206+
steps {
207+
script {
208+
docker.image("harbor-repo.vmware.com/dockerhub-proxy-cache/springci/spring-data-with-valkey-7.2:${p['java.main.tag']}").inside('-v $HOME:/tmp/jenkins-home') {
209+
sh "PROFILE=none LONG_TESTS=true JENKINS_USER_NAME=${p['jenkins.user.name']} ci/test.sh"
210+
}
211+
}
212+
}
213+
}
175214
}
176215
}
177216

‎Makefile‎

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
REDIS_VERSION:=7.2.5
15+
VERSION:=7.2.5
1616
PROJECT?=redis
1717
GH_ORG?=redis
1818
SPRING_PROFILE?=ci
@@ -177,10 +177,10 @@ clobber:
177177
work/$(PROJECT)/bin/$(PROJECT)-cli work/$(PROJECT)/bin/$(PROJECT)-server:
178178
@mkdir -p work/$(PROJECT)
179179

180-
curl -sSL https://github.com/$(GH_ORG)/$(PROJECT)/archive/refs/tags/$(REDIS_VERSION).tar.gz | tar xzf - -C work
181-
$(MAKE) -C work/$(PROJECT)-$(REDIS_VERSION) -j
182-
$(MAKE) -C work/$(PROJECT)-$(REDIS_VERSION) PREFIX=$(shell pwd)/work/$(PROJECT) install
183-
rm -rf work/$(PROJECT)-$(REDIS_VERSION)
180+
curl -sSL https://github.com/$(GH_ORG)/$(PROJECT)/archive/refs/tags/$(VERSION).tar.gz | tar xzf - -C work
181+
$(MAKE) -C work/$(PROJECT)-$(VERSION) -j
182+
$(MAKE) -C work/$(PROJECT)-$(VERSION) PREFIX=$(shell pwd)/work/$(PROJECT) install
183+
rm -rf work/$(PROJECT)-$(VERSION)
184184

185185
start: server-start sentinel-start cluster-init
186186

@@ -198,14 +198,14 @@ stop: server-stop sentinel-stop cluster-stop
198198
test:
199199
$(MAKE) start
200200
sleep 1
201-
./mvnw clean test -U -P$(SPRING_PROFILE) -Dredis.server.version=$(REDIS_VERSION)|| (echo "maven failed $$?"; exit 1)
201+
./mvnw clean test -U -P$(SPRING_PROFILE) || (echo "maven failed $$?"; exit 1)
202202
$(MAKE) stop
203203
$(MAKE) clean
204204

205205
all-tests:
206206
$(MAKE) start
207207
sleep 1
208-
./mvnw clean test -U -DrunLongTests=true -P$(SPRING_PROFILE) -Dredis.server.version=$(REDIS_VERSION)|| (echo "maven failed $$?"; exit 1)
208+
./mvnw clean test -U -DrunLongTests=true -P$(SPRING_PROFILE) || (echo "maven failed $$?"; exit 1)
209209
$(MAKE) stop
210210
$(MAKE) clean
211211

‎ci/openjdk17-redis-6.2/Dockerfile‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
ARG BASE
22
FROM ${BASE}
33
# Any ARG statements before FROM are cleared.
4-
ARG REDIS
4+
ARG VERSION
5+
ENV VERSION=${VERSION}
56

67
# Copy Spring Data Redis's Makefile into the container
78
COPY ./Makefile /
@@ -10,7 +11,7 @@ RUN set -eux; \
1011
# sed -i -e 's/http/https/g' /etc/apt/sources.list ; \
1112
apt-get update ; \
1213
apt-get install -y build-essential ; \
13-
make work/redis/bin/redis-cli work/redis/bin/redis-server REDIS_VERSION=${REDIS}; \
14+
make work/redis/bin/redis-cli work/redis/bin/redis-server VERSION=${VERSION}; \
1415
chmod -R o+rw work; \
1516
apt-get clean; \
1617
rm -rf /var/lib/apt/lists/*;

‎ci/openjdk17-redis-7.2/Dockerfile‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
ARG BASE
22
FROM ${BASE}
33
# Any ARG statements before FROM are cleared.
4-
ARG REDIS
5-
ENV REDIS_VERSION=${REDIS}
4+
ARG VERSION
5+
ENV VERSION=${VERSION}
66

77
# Copy Spring Data Redis's Makefile into the container
88
COPY ./Makefile /
@@ -11,7 +11,7 @@ RUN set -eux; \
1111
# sed -i -e 's/http/https/g' /etc/apt/sources.list ; \
1212
apt-get update ; \
1313
apt-get install -y build-essential ; \
14-
make work/redis/bin/redis-cli work/redis/bin/redis-server REDIS_VERSION=${REDIS}; \
14+
make work/redis/bin/redis-cli work/redis/bin/redis-server VERSION=${VERSION}; \
1515
chmod -R o+rw work; \
1616
apt-get clean; \
1717
rm -rf /var/lib/apt/lists/*;

‎ci/openjdk17-valkey-7.2/Dockerfile‎

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
ARG BASE
2+
FROM ${BASE}
3+
# Any ARG statements before FROM are cleared.
4+
ARG VERSION
5+
ENV VERSION=${VERSION}
6+
ENV PROJECT=valkey
7+
ENV GH_ORG=valkey-io
8+
9+
# Copy Spring Data Redis's Makefile into the container
10+
COPY ./Makefile /
11+
12+
RUN set -eux; \
13+
# sed -i -e 's/http/https/g' /etc/apt/sources.list ; \
14+
apt-get update ; \
15+
apt-get install -y build-essential ; \
16+
make work/valkey/bin/valkey-cli work/valkey/bin/valkey-server VERSION=${VERSION}; \
17+
chmod -R o+rw work; \
18+
apt-get clean; \
19+
rm -rf /var/lib/apt/lists/*;

‎ci/openjdk21-redis-6.2/Dockerfile‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
ARG BASE
22
FROM ${BASE}
33
# Any ARG statements before FROM are cleared.
4-
ARG REDIS
4+
ARG VERSION
5+
ENV VERSION=${VERSION}
56

67
# Copy Spring Data Redis's Makefile into the container
78
COPY ./Makefile /
@@ -10,7 +11,7 @@ RUN set -eux; \
1011
# sed -i -e 's/http/https/g' /etc/apt/sources.list ; \
1112
apt-get update ; \
1213
apt-get install -y build-essential ; \
13-
make work/redis/bin/redis-cli work/redis/bin/redis-server REDIS_VERSION=${REDIS}; \
14+
make work/redis/bin/redis-cli work/redis/bin/redis-server VERSION=${VERSION}; \
1415
chmod -R o+rw work; \
1516
apt-get clean; \
1617
rm -rf /var/lib/apt/lists/*;

‎ci/pipeline.properties‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ docker.mongodb.7.0.version=7.0.2
1414

1515
# Supported versions of Redis
1616
docker.redis.6.version=6.2.13
17-
docker.redis.7.version=7.2.4
17+
docker.redis.7.version=7.2.5
1818

1919
# Supported versions of Cassandra
2020
docker.cassandra.3.version=3.11.16

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /