@@ -22,8 +22,8 @@ concurrency:
22
22
cancel-in-progress : true
23
23
24
24
jobs :
25
- prepare-sql -tests :
26
- name : Prepare for SQL Integration Tests
25
+ prepare-integration -tests :
26
+ name : Prepare for Integration Tests
27
27
runs-on : ubuntu-20.04
28
28
if : github.repository_owner == 'Apicurio' && !contains(github.event.*.labels.*.name, 'DO NOT MERGE')
29
29
steps :
@@ -41,44 +41,12 @@ jobs:
41
41
- name : Get maven wrapper
42
42
run : mvn -N io.takari:maven:wrapper -Dmaven=3.8.2
43
43
44
- - name : Build Sql Variant
45
- run : make SKIP_TESTS =true BUILD_FLAGS=' -Dmaven.javadoc.skip=true --no-transfer-progress - Dmaven.wagon.httpconnectionManager.maxTotal=30 -Dmaven.wagon.http.retryHandler.count=5' build-sql
44
+ - name : Build Application
45
+ run : ./mvnw -T 1.5C clean install --no-transfer-progress -Pprod -DskipTests =true -Dmaven.javadoc.skip=true -Dmaven.wagon.httpconnectionManager.maxTotal=30 -Dmaven.wagon.http.retryHandler.count=5
46
46
47
- - name : Build and Push Sql image
48
- env :
49
- IMAGE_REPO : ttl.sh/${{ github.sha }}
50
- # maximum allowed
51
- IMAGE_TAG : 1d
52
- run : make build-sql-image push-sql-image
53
-
54
- prepare-kafkasql-tests :
55
- name : Prepare for KafkaSQL Integration Tests
56
- runs-on : ubuntu-20.04
57
- if : github.repository_owner == 'Apicurio' && !contains(github.event.*.labels.*.name, 'DO NOT MERGE')
58
- steps :
59
- - name : Show Actor
60
- run : echo ${{github.actor}}
61
- - name : Checkout Code
62
- uses : actions/checkout@v3
63
- - name : Set up JDK 17
64
- uses : actions/setup-java@v3
65
- with :
66
- java-version : ' 17'
67
- distribution : ' temurin'
68
- cache : ' maven'
69
-
70
- - name : Get maven wrapper
71
- run : mvn -N io.takari:maven:wrapper -Dmaven=3.8.2
72
-
73
- - name : Build kafkasql Variant
74
- run : make SKIP_TESTS=true BUILD_FLAGS='-Dmaven.javadoc.skip=true --no-transfer-progress -Dmaven.wagon.httpconnectionManager.maxTotal=30 -Dmaven.wagon.http.retryHandler.count=5' build-kafkasql
75
-
76
- - name : Build and Push kafkasql image
77
- env :
78
- IMAGE_REPO : ttl.sh/${{ github.sha }}
79
- # maximum allowed
80
- IMAGE_TAG : 1d
81
- run : make build-kafkasql-image push-kafkasql-image
47
+ - name : Build and Push Application image
48
+ run : |
49
+ docker build --push -f ./distro/docker/target/docker/Dockerfile.jvm -t ttl.sh/${{ github.sha }}/apicurio/apicurio-registry:1d ./distro/docker/target/docker
82
50
83
51
prepare-ui-tests :
84
52
name : Prepare for UI Integration Tests
@@ -91,33 +59,13 @@ jobs:
91
59
- name : Checkout Code
92
60
uses : actions/checkout@v3
93
61
94
- - name : Set up JDK 17
95
- uses : actions/setup-java@v3
96
- with :
97
- java-version : ' 17'
98
- distribution : ' temurin'
99
- cache : ' maven'
100
-
101
62
- name : Set up Node
102
63
uses : actions/setup-node@v3
103
64
with :
104
65
node-version : 16
105
66
cache : ' npm'
106
67
cache-dependency-path : ' ui/**/package-lock.json'
107
68
108
- - name : Get maven wrapper
109
- run : mvn -N io.takari:maven:wrapper -Dmaven=3.8.2
110
-
111
- - name : Build In-Memory Variant
112
- run : make SKIP_TESTS=true BUILD_FLAGS='-Dmaven.javadoc.skip=true --no-transfer-progress -Dmaven.wagon.httpconnectionManager.maxTotal=30 -Dmaven.wagon.http.retryHandler.count=5' build-in-memory
113
-
114
- - name : Build and Push In-Memory image
115
- env :
116
- IMAGE_REPO : ttl.sh/${{ github.sha }}
117
- # maximum allowed
118
- IMAGE_TAG : 1d
119
- run : make build-mem-image push-mem-image
120
-
121
69
- name : Install UI Dependencies
122
70
run : |
123
71
cd ui
@@ -144,10 +92,55 @@ jobs:
144
92
docker build -t $IMAGE_REPO/apicurio/apicurio-registry-ui:$IMAGE_TAG .
145
93
docker push $IMAGE_REPO/apicurio/apicurio-registry-ui:$IMAGE_TAG
146
94
147
- integration-tests-sql :
148
- name : Integration Tests SQL
95
+ integration-tests-h2 :
96
+ name : Integration Tests H2
97
+ runs-on : ubuntu-20.04
98
+ needs : prepare-integration-tests
99
+ steps :
100
+ - name : Checkout Code
101
+ uses : actions/checkout@v3
102
+ - name : Set up JDK 17
103
+ uses : actions/setup-java@v3
104
+ with :
105
+ java-version : ' 17'
106
+ distribution : ' temurin'
107
+ cache : ' maven'
108
+
109
+ - name : Setup Minikube
110
+ uses : manusa/actions-setup-minikube@v2.9.0
111
+ with :
112
+ minikube version : ' v1.31.1'
113
+ kubernetes version : ' v1.26.3'
114
+ github token : ${{ secrets.GITHUB_TOKEN }}
115
+ driver : docker
116
+
117
+ - name : Prepare minikube tunnel
118
+ run : minikube tunnel &> /dev/null &
119
+
120
+ - name : Run Integration Tests - H2
121
+ run : ./mvnw -T 1.5C verify -am --no-transfer-progress -Pintegration-tests -Pci -Dregistry-mem-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry:1d -Premote-mem -pl integration-tests -Dmaven.javadoc.skip=true
122
+
123
+ - name : Run Integration Tests - auth - H2
124
+ run : ./mvnw -T 1.5C verify -am --no-transfer-progress -Pintegration-tests -Pauth -Dregistry-mem-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry:1d -Premote-mem -pl integration-tests -Dmaven.javadoc.skip=true
125
+
126
+ - name : Run Integration Tests - migration - H2
127
+ run : ./mvnw -T 1.5C verify -am --no-transfer-progress -Pintegration-tests -Pmigration -Dregistry-mem-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry:1d -Premote-mem -pl integration-tests -Dmaven.javadoc.skip=true
128
+
129
+ - name : Collect logs
130
+ if : failure()
131
+ run : ./.github/scripts/collect_logs.sh
132
+
133
+ - name : Upload tests logs artifacts
134
+ if : failure()
135
+ uses : actions/upload-artifact@v1.0.0
136
+ with :
137
+ name : tests-logs
138
+ path : artifacts
139
+
140
+ integration-tests-postgresql :
141
+ name : Integration Tests Postgresql
149
142
runs-on : ubuntu-20.04
150
- needs : prepare-sql -tests
143
+ needs : prepare-integration -tests
151
144
steps :
152
145
- name : Checkout Code
153
146
uses : actions/checkout@v3
@@ -159,7 +152,7 @@ jobs:
159
152
cache : ' maven'
160
153
161
154
- name : Setup Minikube
162
- uses : manusa/actions-setup-minikube@v2.7.2
155
+ uses : manusa/actions-setup-minikube@v2.9.0
163
156
with :
164
157
minikube version : ' v1.31.1'
165
158
kubernetes version : ' v1.26.3'
@@ -169,14 +162,14 @@ jobs:
169
162
- name : Prepare minikube tunnel
170
163
run : minikube tunnel &> /dev/null &
171
164
172
- - name : Run Integration Tests - sql
173
- run : make REGISTRY_IMAGE='- Dregistry-sql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry-sql :1d' run- sql- integration-tests
165
+ - name : Run Integration Tests - Postgresql
166
+ run : ./mvnw -T 1.5C verify -am --no-transfer-progress -Pintegration-tests -Pci - Dregistry-sql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry:1d -Premote- sql -pl integration-tests -Dmaven.javadoc.skip=true
174
167
175
- - name : Run Integration Tests - sql - auth
176
- run : make REGISTRY_IMAGE='- Dregistry-sql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry-sql :1d' run- sql-auth -tests
168
+ - name : Run Integration Tests - auth - Postgresql
169
+ run : ./mvnw -T 1.5C verify -am --no-transfer-progress -Pintegration-tests -Pauth - Dregistry-sql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry:1d -Premote- sql -pl integration -tests -Dmaven.javadoc.skip=true
177
170
178
- - name : Run Integration Tests - sql - migration
179
- run : make REGISTRY_IMAGE='- Dregistry-sql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry-sql :1d' run- sql-migration- integration-tests
171
+ - name : Run Integration Tests - migration - Postgresql
172
+ run : ./mvnw -T 1.5C verify -am --no-transfer-progress -Pintegration-tests -Pmigration - Dregistry-sql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry:1d -Premote- sql -pl integration-tests -Dmaven.javadoc.skip=true
180
173
181
174
- name : Collect logs
182
175
if : failure()
@@ -189,10 +182,11 @@ jobs:
189
182
name : tests-logs
190
183
path : artifacts
191
184
185
+
192
186
integration-tests-kafkasql :
193
187
name : Integration Tests KafkaSql
194
188
runs-on : ubuntu-20.04
195
- needs : prepare-kafkasql -tests
189
+ needs : prepare-integration -tests
196
190
steps :
197
191
- name : Checkout Code
198
192
uses : actions/checkout@v3
@@ -204,7 +198,7 @@ jobs:
204
198
cache : ' maven'
205
199
206
200
- name : Setup Minikube
207
- uses : manusa/actions-setup-minikube@v2.7.2
201
+ uses : manusa/actions-setup-minikube@v2.9.0
208
202
with :
209
203
minikube version : ' v1.31.1'
210
204
kubernetes version : ' v1.26.3'
@@ -214,18 +208,19 @@ jobs:
214
208
- name : Prepare minikube tunnel
215
209
run : minikube tunnel &> /dev/null &
216
210
217
- - name : Run Integration Tests - KafkaSql
218
- run : make REGISTRY_IMAGE='- Dregistry-kafkasql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry-kafkasql :1d' run-kafkasql- integration-tests
211
+ - name : Run Integration Tests - Kafkasql
212
+ run : ./mvnw -T 1.5C verify -am --no-transfer-progress -Pintegration-tests -Pci - Dregistry-kafkasql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry:1d -Premote-kafka -pl integration-tests -Dmaven.javadoc.skip=true
219
213
220
- - name : Run Integration Tests - KafkaSql - Migration
221
- run : make REGISTRY_IMAGE='- Dregistry-kafkasql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry-kafkasql :1d' run-kafkasql-migration- integration-tests
214
+ - name : Run Integration Tests - auth - Kafkasql
215
+ run : ./mvnw -T 1.5C verify -am --no-transfer-progress -Pintegration-tests -Pauth - Dregistry-kafkasql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry:1d -Premote-kafka -pl integration-tests -Dmaven.javadoc.skip=true
222
216
223
- - name : Run Integration Tests - KafkaSql - Auth
224
- run : make REGISTRY_IMAGE='- Dregistry-kafkasql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry-kafkasql :1d' run-kafkasql-auth- tests
217
+ - name : Run Integration Tests - migration - Kafkasql
218
+ run : ./mvnw -T 1.5C verify -am --no-transfer-progress -Pintegration-tests -Pmigration - Dregistry-kafkasql-image=ttl.sh/${{ github.sha }}/apicurio/apicurio-registry:1d -Premote-kafka -pl integration- tests -Dmaven.javadoc.skip=true
225
219
226
220
- name : Collect logs
227
221
if : failure()
228
222
run : ./.github/scripts/collect_logs.sh
223
+
229
224
- name : Upload tests logs artifacts
230
225
if : failure()
231
226
uses : actions/upload-artifact@v1.0.0
@@ -236,7 +231,7 @@ jobs:
236
231
integration-tests-ui :
237
232
name : Integration Tests UI
238
233
runs-on : ubuntu-20.04
239
- needs : prepare-ui-tests
234
+ needs : [ prepare-ui-tests, prepare-integration-tests]
240
235
steps :
241
236
- name : Checkout Code
242
237
uses : actions/checkout@v3
@@ -251,7 +246,7 @@ jobs:
251
246
- name : Run UI tests
252
247
run : |
253
248
echo "Starting Registry App (In Memory)"
254
- docker run -it -p 8080:8080 -d --env CORS_ALLOWED_ORIGINS=* ttl.sh/${{ github.sha }}/apicurio/apicurio-registry-mem :1d
249
+ docker run -it -p 8080:8080 -d --env CORS_ALLOWED_ORIGINS=* ttl.sh/${{ github.sha }}/apicurio/apicurio-registry:1d
255
250
echo "Starting Registry UI"
256
251
docker run -it -p 8888:8080 -d ttl.sh/${{ github.sha }}/apicurio/apicurio-registry-ui:1d
257
252
0 commit comments