-
Notifications
You must be signed in to change notification settings - Fork 9
/
config.yml
184 lines (179 loc) · 4.23 KB
/
config.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
# the global configuration allows you to turn on specific features
global:
machine: true
netviz: true
loaders: true
services: true
chaos: true
dbmon: true
# apm settings are merged with your default settings.
apm:
applicationName: my_apm_game
eum:
appKey: EC-AAB-FTU
services:
frontend:
type: nodejs
labels:
version: 1.0
dc: WEST
agent: yes
port: 3000
aliases:
- www.ecommer.ce
endpoints:
http:
/checkout:
- log,INFO,Checkout
- http://backend/cart/checkout
- cache,128
- image,http://cdn.in-the.cloud/logo.png
- script,http://cdn.in-the.cloud/scrips.js
/addtocart:
- [http://backend/cart/add, http://backendv2/cart/add, http://backendv3/cart/add]
- ajax,http://search-service/search
- ajax,http://www.ecommer.ce/search
- image,http://cdn.in-the.cloud/logo.png
- log,INFO,Add product to cart
/search:
- code,search.js
- http://search-service/search
backend:
type: java
agent: yes
port: 3009
endpoints:
http:
/cart/checkout:
- cache,1024
- - call: http://api.easy.pay/pay
remoteTimeout: 2000
- call: http://api-prod.pay.me/pay
remoteTimeout: 2000
- call: http://api.payster.net/pay
remoteTimeout: 2000
- call: http://api.easy.pay/pay
remoteTimeout: 2000
- call: http://api-prod.pay.me/pay
remoteTimeout: 2000
- call: http://api.easy.pay/pay
remoteTimeout: 2000
/cart/add:
- cache,128
- call: slow,800
probability: 0.1
- image,http://cdn.in-the.cloud/logo.png
- call: data
id: price
type: double
value: [1,2,3]
/api/list:
- cache,1024
- log,WARN,Slow cache detected.
backendv2:
type: java
agent: yes
port: 3010
endpoints:
http:
/cart/add:
- sql://backend-db/shop?query=INSERT INTO carts(name,value) VALUES("test","123")
- call: slow,800
probability: 0.5
- image,http://cdn.in-the.cloud/logo.png
/api/list:
- cache,128
backendv3:
type: php
agent: yes
port: 3007
endpoints:
http:
/cart/add:
- sql://backend-db/shop?query=INSERT INTO carts(name,value) VALUES("test","123")
- call: slow,800
probability: 0.5
/api/list:
- cache,128
search-service:
type: dotnet
agent: yes
port: 3008
endpoints:
http:
/search:
- slow,100
- http://backendv3/api/list
- http://backendv2/api/list
- http://backend/api/list
ext-payment:
type: nodejs
agent: no
aliases: [api.easy.pay, api-prod.pay.me]
endpoints:
http:
pay:
- call: sleep,8000
schedule: "* */2 * * * * *"
- call: error,500,Oopsi
schedule: "* */3 * * * * *"
- sleep,500
api.payster.net:
type: nodejs
agent: no
options:
lossRate: 0.1
connectionDelay: 250
port: 3001
endpoints:
http:
pay:
- call: error,500,Payment failed
probability: 0.5
- sleep,3000
cdn.in-the.cloud:
type: nodejs
agent: no
port: 3002
options:
connectionDelay: 5000
endpoints:
http:
logo.png:
- sleep,1200
backend-db:
type: mysql
databases:
shop:
carts: [id, name, value]
customers: [id, name, email]
loaders:
browser:
type: puppeteer
wait: 15
count: 2
urls:
- http://www.ecommer.ce/addtocart
- http://www.ecommer.ce/addtocart
- http://www.ecommer.ce/checkout
chaos:
pause-cdn.in-the.cloud:
type: pumba
interval: 1m
target: cdn.in-the.cloud
command: pause
duration: 5s
network-loss:
type: pumba
interval: 5m
target: [frontend, backend]
command: netem-loss
duration: 1m
probability: 25
network-delay:
type: pumba
interval: 8m
target: backendv3
command: netem-delay
duration: 30s
time: 5000