forked from aeraki-mesh/meta-protocol-proxy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
test.yaml
240 lines (239 loc) · 8.96 KB
/
test.yaml
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
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
admin:
access_log_path: ./envoy_debug.log
address:
socket_address:
address: 127.0.0.1
port_value: 8080
node:
cluster: dubbo-sample-consumer.metaprotocol
id: sidecar~10.244.0.14~dubbo-sample-consumer-797c4f7cc4-t678c.meta-dubbo~meta-dubbo.svc.cluster.local
metadata:
ANNOTATIONS:
kubectl.kubernetes.io/default-container: dubbo-sample-consumer
kubectl.kubernetes.io/default-logs-container: dubbo-sample-consumer
APP_CONTAINERS: dubbo-sample-consumer
CLUSTER_ID: Kubernetes
INTERCEPTION_MODE: REDIRECT
LABELS:
app: dubbo-sample-consumer
pod-template-hash: 797c4f7cc4
security.istio.io/tlsMode: istio
service.istio.io/canonical-name: dubbo-sample-consumer
service.istio.io/canonical-revision: latest
MESH_ID: cluster.local
NAME: dubbo-sample-consumer-797c4f7cc4-t678c
NAMESPACE: meta-dubbo
OWNER: kubernetes://apis/apps/v1/namespaces/meta-dubbo/deployments/dubbo-sample-consumer
PROXY_CONFIG:
binaryPath: /usr/local/bin/envoy
controlPlaneAuthPolicy: MUTUAL_TLS
discoveryAddress: istiod.istio-system.svc:15012
proxyAdminPort: 15000
proxyMetadata:
ISTIO_META_DNS_CAPTURE: "true"
serviceCluster: istio-proxy
SERVICE_ACCOUNT: default
WORKLOAD_NAME: dubbo-sample-consumer
stats_config:
stats_tags:
- regex: ^cluster\.((.+?(\..+?\.svc\.cluster\.local)?)\.)
tag_name: cluster_name
- regex: ^tcp\.((.*?)\.)\w+?$
tag_name: tcp_prefix
- regex: (response_code=\.=(.+?);\.;)|_rq(_(\.d{3}))$
tag_name: response_code
- regex: _rq(_(\dxx))$
tag_name: response_code_class
- regex: ^listener(?=\.).*?\.http\.(((?:[_.[:digit:]]*|[_\[\]aAbBcCdDeEfF[:digit:]]*))\.)
tag_name: http_conn_manager_listener_prefix
- regex: ^http\.(((?:[_.[:digit:]]*|[_\[\]aAbBcCdDeEfF[:digit:]]*))\.)
tag_name: http_conn_manager_prefix
- regex: ^listener\.(((?:[_.[:digit:]]*|[_\[\]aAbBcCdDeEfF[:digit:]]*))\.)
tag_name: listener_address
- regex: ^mongo\.(.+?)\.(collection|cmd|cx_|op_|delays_|decoding_)(.*?)$
tag_name: mongo_prefix
- regex: (reporter=\.=(.*?);\.;)
tag_name: reporter
- regex: (source_namespace=\.=(.*?);\.;)
tag_name: source_namespace
- regex: (source_workload=\.=(.*?);\.;)
tag_name: source_workload
- regex: (source_workload_namespace=\.=(.*?);\.;)
tag_name: source_workload_namespace
- regex: (source_principal=\.=(.*?);\.;)
tag_name: source_principal
- regex: (source_app=\.=(.*?);\.;)
tag_name: source_app
- regex: (source_version=\.=(.*?);\.;)
tag_name: source_version
- regex: (source_cluster=\.=(.*?);\.;)
tag_name: source_cluster
- regex: (destination_namespace=\.=(.*?);\.;)
tag_name: destination_namespace
- regex: (destination_workload=\.=(.*?);\.;)
tag_name: destination_workload
- regex: (destination_workload_namespace=\.=(.*?);\.;)
tag_name: destination_workload_namespace
- regex: (destination_principal=\.=(.*?);\.;)
tag_name: destination_principal
- regex: (destination_app=\.=(.*?);\.;)
tag_name: destination_app
- regex: (destination_version=\.=(.*?);\.;)
tag_name: destination_version
- regex: (destination_service=\.=(.*?);\.;)
tag_name: destination_service
- regex: (destination_service_name=\.=(.*?);\.;)
tag_name: destination_service_name
- regex: (destination_service_namespace=\.=(.*?);\.;)
tag_name: destination_service_namespace
- regex: (destination_port=\.=(.*?);\.;)
tag_name: destination_port
- regex: (destination_cluster=\.=(.*?);\.;)
tag_name: destination_cluster
- regex: (request_protocol=\.=(.*?);\.;)
tag_name: request_protocol
- regex: (request_operation=\.=(.*?);\.;)
tag_name: request_operation
- regex: (request_host=\.=(.*?);\.;)
tag_name: request_host
- regex: (response_flags=\.=(.*?);\.;)
tag_name: response_flags
- regex: (grpc_response_status=\.=(.*?);\.;)
tag_name: grpc_response_status
- regex: (connection_security_policy=\.=(.*?);\.;)
tag_name: connection_security_policy
- regex: (source_canonical_service=\.=(.*?);\.;)
tag_name: source_canonical_service
- regex: (destination_canonical_service=\.=(.*?);\.;)
tag_name: destination_canonical_service
- regex: (source_canonical_revision=\.=(.*?);\.;)
tag_name: source_canonical_revision
- regex: (destination_canonical_revision=\.=(.*?);\.;)
tag_name: destination_canonical_revision
- regex: (cache\.(.+?)\.)
tag_name: cache
- regex: (component\.(.+?)\.)
tag_name: component
- regex: (tag\.(.+?);\.)
tag_name: tag
- regex: (wasm_filter\.(.+?)\.)
tag_name: wasm_filter
- regex: rbac(\.(allowed|denied))
tag_name: authz_enforce_result
- regex: (\.istio_dry_run_(allow|deny)_)
tag_name: authz_dry_run_action
- regex: (\.shadow_(allowed|denied))
tag_name: authz_dry_run_result
use_all_default_tags: false
tracing:
http:
name: envoy.tracers.zipkin
typed_config:
'@type': type.googleapis.com/envoy.config.trace.v3.ZipkinConfig
collector_cluster: "zipkin"
collector_endpoint: "/api/v2/spans"
trace_id_128bit: true
shared_span_context: false
collector_endpoint_version: "HTTP_JSON"
static_resources:
listeners:
name: listener_meta_protocol
address:
socket_address:
address: 0.0.0.0
port_value: 20880
traffic_direction: OUTBOUND
filter_chains:
- filters:
- name: aeraki.meta_protocol_proxy
typed_config:
'@type': type.googleapis.com/aeraki.meta_protocol_proxy.v1alpha.MetaProtocolProxy
protocol:
name: dubbo
codec:
name: aeraki.meta_protocol.codec.dubbo
multiplexing: true
tracing:
client_sampling:
value: 100
random_sampling:
value: 100
overall_sampling:
value: 100
metaProtocolFilters:
- name: aeraki.meta_protocol.filters.metadata_exchange
- name: aeraki.meta_protocol.filters.istio_stats
config:
'@type': type.googleapis.com/aeraki.meta_protocol_proxy.filters.istio_stats.v1alpha.IstioStats
destination_service: org.apache.dubbo.samples.basic.api.demoservice
- name: aeraki.meta_protocol.filters.router
routeConfig:
routes:
- name: default-route
match:
metadata:
- name: interface
exact_match: org.apache.dubbo.samples.basic.api.DemoService
- name: method
exact_match: sayHello
- name: foo
exact_match: bar
route:
cluster: outbound|20880||org.apache.dubbo.samples.basic.api.demoservice
request_mirror_policies:
- cluster: outbound|20880||org.apache.dubbo.samples.basic.api.demoservice.mirror
runtime_fraction:
default_value:
numerator: 50
request_mutation:
- key: foo
value: bar
- key: foo1
value: bar1
statPrefix: outbound|20880||org.apache.dubbo.samples.basic.api.demoservice
access_log:
- name: envoy.access_loggers.file
typed_config:
'@type': type.googleapis.com/envoy.extensions.access_loggers.file.v3.FileAccessLog
log_format:
text_format_source:
inline_string: |
[%START_TIME%] "%REQ(X-REQUEST-ID)% %REQ(X-META-PROTOCOL-APPLICATION-PROTOCOL)% %REQ(INTERFACE)% %REQ(METHOD)% %RESPONSE_CODE% %RESPONSE_CODE_DETAILS% %CONNECTION_TERMINATION_DETAILS% "%UPSTREAM_TRANSPORT_FAILURE_REASON%" %BYTES_RECEIVED% %BYTES_SENT% %DURATION% %RESP(X-ENVOY-UPSTREAM-SERVICE-TIME)% %UPSTREAM_CLUSTER% %UPSTREAM_LOCAL_ADDRESS% %DOWNSTREAM_LOCAL_ADDRESS% %DOWNSTREAM_REMOTE_ADDRESS% %ROUTE_NAME%
path: /dev/stdout
clusters:
- name: outbound|20880||org.apache.dubbo.samples.basic.api.demoservice
type: STATIC
connect_timeout: 5s
load_assignment:
cluster_name: outbound|20880||org.apache.dubbo.samples.basic.api.demoservice
endpoints:
- lb_endpoints:
- endpoint:
address:
socket_address:
address: 127.0.0.1
port_value: 20881
- name: outbound|20880||org.apache.dubbo.samples.basic.api.demoservice.mirror
type: STATIC
connect_timeout: 5s
load_assignment:
cluster_name: outbound|20880||org.apache.dubbo.samples.basic.api.demoservice.mirror
endpoints:
- lb_endpoints:
- endpoint:
address:
socket_address:
address: 127.0.0.1
port_value: 20882
- name: zipkin
type: STATIC
connect_timeout: 5s
load_assignment:
cluster_name: zipkin
endpoints:
- lb_endpoints:
- endpoint:
address:
socket_address:
address: 127.0.0.1
port_value: 9411