Skip to content

Commit 168dcae

Browse files
authored
Adding both etcd and property schema test in each E2E (#994)
1 parent 0959cab commit 168dcae

18 files changed

+480
-18
lines changed

.github/workflows/e2e.yml

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -56,14 +56,22 @@ jobs:
5656
fail-fast: false
5757
matrix:
5858
test:
59-
- name: BanyanDB
60-
config: test/e2e-v2/cases/storage/banyandb/e2e.yaml
61-
- name: Trace Profiling BanyanDB
62-
config: test/e2e-v2/cases/profiling/trace/banyandb/e2e.yaml
63-
- name: Event BanyanDB
64-
config: test/e2e-v2/cases/event/banyandb/e2e.yaml
65-
- name: BanyanDB Cluster Mode
66-
config: test/e2e-v2/cases/cluster/e2e.yaml
59+
- name: BanyanDB Etcd
60+
config: test/e2e-v2/cases/storage/banyandb/e2e-etcd.yaml
61+
- name: BanyanDB Property
62+
config: test/e2e-v2/cases/storage/banyandb/e2e-property.yaml
63+
- name: Trace Profiling BanyanDB Etcd
64+
config: test/e2e-v2/cases/profiling/trace/banyandb/e2e-etcd.yaml
65+
- name: Trace Profiling BanyanDB Property
66+
config: test/e2e-v2/cases/profiling/trace/banyandb/e2e-property.yaml
67+
- name: Event BanyanDB Etcd
68+
config: test/e2e-v2/cases/event/banyandb/e2e-etcd.yaml
69+
- name: Event BanyanDB Property
70+
config: test/e2e-v2/cases/event/banyandb/e2e-property.yaml
71+
- name: BanyanDB Cluster Mode Etcd
72+
config: test/e2e-v2/cases/cluster/e2e-etcd.yaml
73+
- name: BanyanDB Cluster Mode Property
74+
config: test/e2e-v2/cases/cluster/e2e-property.yaml
6775
# TODO: Enable Lifecycle test when it is ready
6876
# - name: Lifecycle
6977
# config: test/e2e-v2/cases/lifecycle/e2e.yaml

test/docker/base-compose.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ services:
1919
- 17912
2020
- 2121
2121
- 6060
22-
command: standalone --schema-registry-mode=etcd
22+
command: standalone
2323
healthcheck:
2424
test: ["CMD", "./bydbctl", "health", "--config=-", "--addr=http://banyandb:17913"]
2525
interval: 5s
@@ -34,7 +34,7 @@ services:
3434
- 17912
3535
- 2121
3636
- 6060
37-
command: liaison --etcd-endpoints=http://etcd:2379 --schema-registry-mode=etcd
37+
command: liaison --etcd-endpoints=http://etcd:2379
3838
healthcheck:
3939
test: ["CMD", "./bydbctl", "health", "--addr=http://liaison:17913"]
4040
interval: 5s
@@ -48,7 +48,7 @@ services:
4848
- 2121
4949
- 6060
5050
- 17932
51-
command: data --etcd-endpoints=http://etcd:2379 --schema-registry-mode=etcd
51+
command: data --etcd-endpoints=http://etcd:2379
5252
healthcheck:
5353
test: ["CMD", "./bydbctl", "health", "--addr=http://127.0.0.1:17913"]
5454
interval: 5s

test/e2e-v2/cases/cluster/docker-compose.yml renamed to test/e2e-v2/cases/cluster/docker-compose-etcd.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,15 @@ services:
2727
extends:
2828
file: ../../script/docker-compose/base-compose.yml
2929
service: data
30+
command: data --etcd-endpoints=http://etcd:2379 --schema-registry-mode=etcd
3031
networks:
3132
- e2e
3233

3334
liaison:
3435
extends:
3536
file: ../../script/docker-compose/base-compose.yml
3637
service: liaison
38+
command: liaison --etcd-endpoints=http://etcd:2379 --schema-registry-mode=etcd
3739
networks:
3840
- e2e
3941

Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one or more
2+
# contributor license agreements. See the NOTICE file distributed with
3+
# this work for additional information regarding copyright ownership.
4+
# The ASF licenses this file to You under the Apache License, Version 2.0
5+
# (the "License"); you may not use this file except in compliance with
6+
# the License. You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
16+
version: '2.1'
17+
18+
services:
19+
etcd:
20+
extends:
21+
file: ../../script/docker-compose/base-compose.yml
22+
service: etcd
23+
networks:
24+
- e2e
25+
26+
data:
27+
extends:
28+
file: ../../script/docker-compose/base-compose.yml
29+
service: data
30+
command: data --etcd-endpoints=http://etcd:2379 --schema-registry-mode=property --schema-property-client-sync-interval=10s
31+
networks:
32+
- e2e
33+
34+
liaison:
35+
extends:
36+
file: ../../script/docker-compose/base-compose.yml
37+
service: liaison
38+
command: liaison --etcd-endpoints=http://etcd:2379 --schema-registry-mode=property --schema-property-client-sync-interval=10s
39+
networks:
40+
- e2e
41+
42+
oap:
43+
extends:
44+
file: ../../script/docker-compose/base-compose.yml
45+
service: oap
46+
environment:
47+
SW_STORAGE: banyandb
48+
SW_STORAGE_BANYANDB_TARGETS: "liaison:17912"
49+
ports:
50+
- 12800
51+
depends_on:
52+
liaison:
53+
condition: service_healthy
54+
55+
agent:
56+
extends:
57+
file: ../../script/docker-compose/base-compose.yml
58+
service: agent
59+
networks:
60+
- e2e
61+
62+
provider:
63+
extends:
64+
file: ../../script/docker-compose/base-compose.yml
65+
service: provider
66+
ports:
67+
- 9090
68+
networks:
69+
- e2e
70+
depends_on:
71+
oap:
72+
condition: service_healthy
73+
agent:
74+
condition: service_completed_successfully
75+
76+
consumer:
77+
extends:
78+
file: ../../script/docker-compose/base-compose.yml
79+
service: consumer
80+
ports:
81+
- 9092
82+
depends_on:
83+
oap:
84+
condition: service_healthy
85+
provider:
86+
condition: service_healthy
87+
agent:
88+
condition: service_completed_successfully
89+
90+
networks:
91+
e2e:
92+
93+
volumes:
94+
sw_agent:
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
setup:
1919
env: compose
20-
file: docker-compose.yml
20+
file: docker-compose-etcd.yml
2121
timeout: 20m
2222
init-system-environment: ../../script/env
2323
steps:
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one or more
2+
# contributor license agreements. See the NOTICE file distributed with
3+
# this work for additional information regarding copyright ownership.
4+
# The ASF licenses this file to You under the Apache License, Version 2.0
5+
# (the "License"); you may not use this file except in compliance with
6+
# the License. You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
16+
# This file is used to show how to write configuration files and can be used to test.
17+
18+
setup:
19+
env: compose
20+
file: docker-compose-property.yml
21+
timeout: 20m
22+
init-system-environment: ../../script/env
23+
steps:
24+
- name: set PATH
25+
command: export PATH=/tmp/skywalking-infra-e2e/bin:$PATH
26+
- name: install yq
27+
command: bash test/e2e-v2/script/prepare/setup-e2e-shell/install.sh yq
28+
- name: install swctl
29+
command: bash test/e2e-v2/script/prepare/setup-e2e-shell/install.sh swctl
30+
31+
trigger:
32+
action: http
33+
interval: 5s
34+
times: -1
35+
url: http://${consumer_host}:${consumer_9092}/users
36+
method: POST
37+
body: '{"id":"123","name":"skywalking"}'
38+
headers:
39+
"Content-Type": "application/json"
40+
41+
verify:
42+
# verify with retry strategy
43+
retry:
44+
# max retry count
45+
count: 20
46+
# the interval between two retries, in millisecond.
47+
interval: 10s
48+
cases:
49+
- includes:
50+
- ../storage/storage-cases.yaml

test/e2e-v2/cases/event/banyandb/docker-compose.yml renamed to test/e2e-v2/cases/event/banyandb/docker-compose-etcd.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ services:
1818
extends:
1919
file: ../../../script/docker-compose/base-compose.yml
2020
service: banyandb
21+
command: standalone --schema-registry-mode=etcd
2122
networks:
2223
- e2e
2324

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one or more
2+
# contributor license agreements. See the NOTICE file distributed with
3+
# this work for additional information regarding copyright ownership.
4+
# The ASF licenses this file to You under the Apache License, Version 2.0
5+
# (the "License"); you may not use this file except in compliance with
6+
# the License. You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
16+
services:
17+
banyandb:
18+
extends:
19+
file: ../../../script/docker-compose/base-compose.yml
20+
service: banyandb
21+
command: standalone --schema-registry-mode=property --schema-property-client-sync-interval=10s
22+
networks:
23+
- e2e
24+
25+
oap:
26+
extends:
27+
file: ../../../script/docker-compose/base-compose.yml
28+
service: oap
29+
environment:
30+
SW_STORAGE: banyandb
31+
depends_on:
32+
banyandb:
33+
condition: service_healthy
34+
ports:
35+
- 11800
36+
- 12800
37+
38+
networks:
39+
e2e:

test/e2e-v2/cases/event/banyandb/e2e.yaml renamed to test/e2e-v2/cases/event/banyandb/e2e-etcd.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
setup:
1919
env: compose
20-
file: docker-compose.yml
20+
file: docker-compose-etcd.yml
2121
timeout: 20m
2222
init-system-environment: ../../../script/env
2323
steps:
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one or more
2+
# contributor license agreements. See the NOTICE file distributed with
3+
# this work for additional information regarding copyright ownership.
4+
# The ASF licenses this file to You under the Apache License, Version 2.0
5+
# (the "License"); you may not use this file except in compliance with
6+
# the License. You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
16+
# This file is used to show how to write configuration files and can be used to test.
17+
18+
setup:
19+
env: compose
20+
file: docker-compose-property.yml
21+
timeout: 20m
22+
init-system-environment: ../../../script/env
23+
steps:
24+
- name: set PATH
25+
command: export PATH=/tmp/skywalking-infra-e2e/bin:$PATH
26+
- name: install yq
27+
command: bash test/e2e-v2/script/prepare/setup-e2e-shell/install.sh yq
28+
- name: install swctl
29+
command: bash test/e2e-v2/script/prepare/setup-e2e-shell/install.sh swctl
30+
31+
verify:
32+
retry:
33+
count: 20
34+
interval: 3s
35+
cases:
36+
- includes:
37+
- ../event-cases.yaml

0 commit comments

Comments
 (0)