-
Notifications
You must be signed in to change notification settings - Fork 47
Expand file tree
/
Copy pathconfig.yaml
More file actions
618 lines (504 loc) · 21.3 KB
/
Copy pathconfig.yaml
File metadata and controls
618 lines (504 loc) · 21.3 KB
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
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
# Copyright AGNTCY Contributors (https://github.com/agntcy)
# SPDX-License-Identifier: Apache-2.0
# Configuration for the tracing
tracing:
# The logging level. Available options:
# - trace
# - debug
# - info
# - warn
# - error
# Default: info
log_level: debug
# Display the thread name in the logs.
# Default: true
display_thread_names: true
# Display the thread ID in the logs.
# Default: false
display_thread_ids: true
opentelemetry:
# Enables OpenTelemetry integration.
# Default: false
enabled: true
# Service name used for the tracing.
# Default: slim-data-plane
service_name: "slim-data-plane"
# Service version used for the tracing.
# Default: v0.1.0
service_version: "v0.1.0"
runtime:
# The number of cores to use for the runtime.
# Default: 0 (use all available cores)
n_cores: 0
# The name of the thread(s) that will run the runtime.
# Default: "slim"
thread_name: "slim-data-plane"
# The timeout for the runtime to wait for the tasks to finish before shutting down.
# Default: 10s
drain_timeout: 10s
# Configuration for the services
services:
# Configuration for the slim service.
# This is the main service that will handle the incoming requests.
slim/0:
# dataplane API configuration
dataplane:
# GRPC Server configuration
servers:
# The endpoint to listen on.
# No default, this must be specified.
- endpoint: "0.0.0.0:46357"
# Transport protocol is inferred from the endpoint scheme:
# ws://, wss:// → websocket (TLS when wss)
# http://, https://, bare host:port, unix:// → grpc
# Authentication configuration
auth:
# Basic authentication configuration. One of the following:
basic:
# The username for the basic authentication.
# No default, this must be specified.
username: "username"
# The password for the basic authentication.
# No default, this must be specified.
password: "password"
jwt:
# Claims for the JWT token. audience and issuer will be used for validation.
claims:
# The audience for the JWT token.
audience: "slim"
# The issuer of the JWT token.
issuer: "slim"
# The subject of the JWT token.
subject: "slim"
# Additional custom claims can be added here.
custom_claims:
custom_key: "custom_value"
# The duration for which the JWT token is valid. Ignored for server-side validation.
duration: 1h
# Key configuration for the JWT token.
key:
# Decoding configuration for the JWT token.
decoding:
# The algorithm used for decoding the JWT token.
algorithm: "ES256"
# The PEM encoded public key used for decoding the JWT token.
# The alternative is to use a file with the public key.
# pem: |
# -----BEGIN PUBLIC KEY-----
# MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE3AOXRAbY5xP09w79HcbI6Fwz3jHE
# UukerJKoy4HHeI7YjEu/WXSm69C7ve8IdyLgFnX+KRUkWfj0R2wTRU4VYQ==
# -----END PUBLIC KEY-----
# file: "testdata/jwt/ecdsa-public.pem"
pem: |
-----BEGIN PUBLIC KEY-----
MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE3AOXRAbY5xP09w79HcbI6Fwz3jHE
UukerJKoy4HHeI7YjEu/WXSm69C7ve8IdyLgFnX+KRUkWfj0R2wTRU4VYQ==
-----END PUBLIC KEY-----
# TLS configuration
tls:
# Whether to enable TLS.
# Default: true
insecure: false
# Enforce client authentication using mTLS, and use
# this CA certificate to verify the client certificate.
# client_ca_file:
# client_ca_pem:
# Path to the CA certificate file.
# If not specified, it will use the system CA certs pool.
# This is used to verify the client certificate in case of mTLS
ca_file: "testdata/ca.crt"
# PEM encoded CA certificate.
# If not specified, it will use the system CA certs pool.
# This is used to verify the client certificate in case of mTLS
# ca_pem: ""
# The path to the certificate file, if TLS is enabled.
# No default, this (or alternatively cert_pem) must be specified.
cert_file: "testdata/server.crt"
# The path to the key file, if TLS is enabled.
# No default, this (or alternatively key_pem) must be specified.
key_file: "testdata/server.key"
# The certificate in PEM format, if TLS is enabled.
# No default, this (or alternatively cert_file) must be specified.
# cert_pem: ""
# The key in PEM format, if TLS is enabled.
# No default, this (or alternatively key_file) must be specified.
# key_pem: ""
# Whether to include the system CA certs pool.
# Default: false
include_system_ca_certs_pool: false
# TLS Version. Available options:
# - tls1.2
# - tls1.3
# Default: tls1.3
tls_version: "tls1.3"
# The certificate reload interval. If set, the server will reload the certificate
# every time the interval is reached.
# reload_interval: 10s
# Whether to enable HTTP/2 only.
# Default: true
http2_only: true
# Maximum size (in MiB) of messages accepted by the server.
# Default: It will default from the underlying transport.
# max_recv_msg_size: 4
# Max concurrent streams per connection.
# Default: 100
# max_concurrent_streams: 100
# Max header list size.
# Default: 16KiB
# max_header_list_size: 8192
# The read buffer size for the server.
# This is currently not used
# read_buffer_size: 4KiB
# The write buffer size for the server.
# This is currently not used
# write_buffer_size: 4KiB
# Keepalive configuration
keepalive:
# Sets the time after which an idle connection is closed.
# Default: 3600s
max_connection_idle: 7200s
# Sets the maximum amount of time a connection may exist before it will be closed.
# Default: 7200s
max_connection_age: 14400s
# Additional time given after MaxConnectionAge before closing the connection.
# Default: 300s
max_connection_age_grace: 300s
# Set the frequency of the keepalive ping.
# Default: 12ß0s
time: 120s
# Sets the amount of time the server waits for a keepalive ping ack.
# Default: 20s
timeout: 20s
# Authenticator configuration.
# This is not currently implemented, but its purpose is to specify an
# authenticator that can authenticate the messages before they are processed.
# authenticator: ""
# GRPC Clients configuration.
clients:
# The endpoint to connect to.
# No default, this must be specified.
- endpoint: "1.2.3.4:54321"
# Transport protocol is inferred from the endpoint scheme:
# ws://, wss:// → websocket (TLS when wss)
# http://, https://, bare host:port, unix:// → grpc
# Optional websocket auth query parameter key.
# Used only when endpoint scheme is ws:// or wss://.
# websocket_auth_query_param: token
# Authentication configuration
auth:
# Basic authentication configuration
basic:
# The username for the basic authentication.
# No default, this must be specified.
username: "username"
# The password for the basic authentication.
# No default, this must be specified.
password: "password"
# Origin configuration
# Default: none
# origin: localhost
# Compression configuration.
# Default: none
# compression: none
# Rate limit configuration. The format is "<limit>/<duration>", with the duration expressed in seconds.
# Default: none
# rate_limit: 20/60 (20 requests every 60 seconds)
# Keepalive parameters
keepalive:
# Sets the TCP keepalive interval
# Default: 10s
tcp_keepalive: 60s
# Sets the http 2 keepalive interval
# Default: 60s
http2_keepalive: 60s
# The timeout duration for the keepalive
# Default: 10s
timeout: 10s
# Whether to permit keepalive without an active stream
# Default: false
permit_without_stream: false
# The timeout for the connection with the server
# Default is None
connection_timeout: 10s
# The timeout for each request
# Default is None
request_timeout: 10s
# The buffer size
# Default is None
buffer_size: 4096
# Additional headers to send with the request
# Default is None
headers:
x-header: value
# authentication configuration.
# not used yet
# auth:
# TLS configuration
tls:
# Whether to enable TLS.
# Default: false
insecure: true
# Whether to skip the server name verification.
# Default: false
insecure_skip_verify: false
# Path to the CA certificate file.
# If not specified, it will use the system CA certs pool.
ca_file: "testdata/ca.crt"
# PEM encoded CA certificate.
# If not specified, it will use the system CA certs pool.
# ca_pem: ""
# The path to the certificate file, if TLS is enabled.
# No default, this (or alternatively cert_pem) must be specified.
# Specifying this effectively enable mTLS.
# cert_file: "testdata/client.crt"
# The path to the key file, if TLS is enabled.
# No default, this (or alternatively key_pem) must be specified.
# Specifying this effectively enable mTLS.
# key_file: "testdata/client.key"
# The certificate in PEM format, if TLS is enabled.
# No default, this (or alternatively cert_file) must be specified.
# Specifying this effectively enable mTLS.
# cert_pem: ""
# The key in PEM format, if TLS is enabled.
# No default, this (or alternatively key_file) must be specified.
# Specifying this effectively enable mTLS.
# key_pem: ""
# TLS Version. Available options:
# - tls1.2
# - tls1.3
# Default: tls1.3
tls_version: "tls1.3"
# The certificate reload interval. If set, the client will reload the certificate
# every time the interval is reached.
# reload_interval: 10s
# controller API configuration
controller:
# GRPC Server configuration
servers:
# The endpoint to listen on.
# No default, this must be specified.
- endpoint: "0.0.0.0:46358"
# Authentication configuration
auth:
# Basic authentication configuration
basic:
# The username for the basic authentication.
# No default, this must be specified.
username: "username"
# The password for the basic authentication.
# No default, this must be specified.
password: "password"
jwt:
# Claims for the JWT token.
claims:
# The audience for the JWT token.
audience: "slim"
# The issuer of the JWT token.
issuer: "slim"
# The subject of the JWT token.
subject: "slim"
# Additional custom claims can be added here.
custom_claims:
custom_key: "custom_value"
# The duration for which the JWT token is valid.
duration: 1h
# Key configuration for the JWT token.
key:
# Decoding configuration for the JWT token.
encoding:
# The algorithm used for decoding the JWT token.
algorithm: "ES256"
# The PEM encoded public key used for decoding the JWT token.
# The alternative is to use a file with the public key.
# pem: |
# -----BEGIN PRIVATE KEY-----
# ...
# -----END PRIVATE KEY-----
# file: "testdata/jwt/ecdsa-public.pem"
pem: |
-----BEGIN PRIVATE KEY-----
...
-----END PRIVATE KEY-----
# TLS configuration
tls:
# Whether to enable TLS.
# Default: true
insecure: false
# Enforce client authentication using mTLS, and use
# this CA certificate to verify the client certificate.
# client_ca_file:
# client_ca_pem:
# Path to the CA certificate file.
# If not specified, it will use the system CA certs pool.
# This is used to verify the client certificate in case of mTLS
ca_file: "testdata/ca.crt"
# PEM encoded CA certificate.
# If not specified, it will use the system CA certs pool.
# This is used to verify the client certificate in case of mTLS
# ca_pem: ""
# The path to the certificate file, if TLS is enabled.
# No default, this (or alternatively cert_pem) must be specified.
cert_file: "testdata/server.crt"
# The path to the key file, if TLS is enabled.
# No default, this (or alternatively key_pem) must be specified.
key_file: "testdata/server.key"
# The certificate in PEM format, if TLS is enabled.
# No default, this (or alternatively cert_file) must be specified.
# cert_pem: ""
# The key in PEM format, if TLS is enabled.
# No default, this (or alternatively key_file) must be specified.
# key_pem: ""
# Whether to include the system CA certs pool.
# Default: false
include_system_ca_certs_pool: false
# TLS Version. Available options:
# - tls1.2
# - tls1.3
# Default: tls1.3
tls_version: "tls1.3"
# The certificate reload interval. If set, the server will reload the certificate
# every time the interval is reached.
# reload_interval: 10s
# Whether to enable HTTP/2 only.
# Default: true
http2_only: true
# Maximum size (in MiB) of messages accepted by the server.
# Default: It will default from the underlying transport.
# max_recv_msg_size: 4
# Max concurrent streams per connection.
# Default: 100
# max_concurrent_streams: 100
# Max header list size.
# Default: 16KiB
# max_header_list_size: 8192
# The read buffer size for the server.
# This is currently not used
# read_buffer_size: 4KiB
# The write buffer size for the server.
# This is currently not used
# write_buffer_size: 4KiB
# Keepalive configuration
keepalive:
# Sets the time after which an idle connection is closed.
# Default: 3600s
max_connection_idle: 7200s
# Sets the maximum amount of time a connection may exist before it will be closed.
# Default: 7200s
max_connection_age: 14400s
# Additional time given after MaxConnectionAge before closing the connection.
# Default: 300s
max_connection_age_grace: 300s
# Set the frequency of the keepalive ping.
# Default: 12ß0s
time: 120s
# Sets the amount of time the server waits for a keepalive ping ack.
# Default: 20s
timeout: 20s
# Authenticator configuration.
# This is not currently implemented, but its purpose is to specify an
# authenticator that can authenticate the messages before they are processed.
# authenticator: ""
# GRPC Client configuration.
clients:
# The endpoint to connect to.
# No default, this must be specified.
- endpoint: "1.2.3.4:54321"
# Authentication configuration
auth:
# Basic authentication configuration
basic:
# The username for the basic authentication.
# No default, this must be specified.
username: "username"
# The password for the basic authentication.
# No default, this must be specified.
password: "password"
# Origin configuration
# Default: none
# origin: localhost
# Compression configuration.
# Default: none
# compression: none
# Rate limit configuration. The format is "<limit>/<duration>", with the duration expressed in seconds.
# Default: none
# rate_limit: 20/60 (20 requests every 60 seconds)
# Keepalive parameters
keepalive:
# Sets the TCP keepalive interval
# Default: 10s
tcp_keepalive: 60s
# Sets the http 2 keepalive interval
# Default: 60s
http2_keepalive: 60s
# The timeout duration for the keepalive
# Default: 10s
timeout: 10s
# Whether to permit keepalive without an active stream
# Default: false
permit_without_stream: false
# The timeout for the connection with the server
# Default is None
connection_timeout: 10s
# The timeout for each request
# Default is None
request_timeout: 10s
# The buffer size
# Default is None
buffer_size: 4096
# Additional headers to send with the request
# Default is None
headers:
x-header: value
# authentication configuration.
# not used yet
# auth:
# TLS configuration
tls:
# Whether to enable TLS.
# Default: false
insecure: true
# Whether to skip the server name verification.
# Default: false
insecure_skip_verify: false
# Path to the CA certificate file.
# If not specified, it will use the system CA certs pool.
ca_file: "testdata/ca.crt"
# PEM encoded CA certificate.
# If not specified, it will use the system CA certs pool.
# ca_pem: ""
# The path to the certificate file, if TLS is enabled.
# No default, this (or alternatively cert_pem) must be specified.
# Specifying this effectively enable mTLS.
# cert_file: "testdata/client.crt"
# The path to the key file, if TLS is enabled.
# No default, this (or alternatively key_pem) must be specified.
# Specifying this effectively enable mTLS.
# key_file: "testdata/client.key"
# The certificate in PEM format, if TLS is enabled.
# No default, this (or alternatively cert_file) must be specified.
# Specifying this effectively enable mTLS.
# cert_pem: ""
# The key in PEM format, if TLS is enabled.
# No default, this (or alternatively key_file) must be specified.
# Specifying this effectively enable mTLS.
# key_pem: ""
# TLS Version. Available options:
# - tls1.2
# - tls1.3
# Default: tls1.3
tls_version: "tls1.3"
# The certificate reload interval. If set, the client will reload the certificate
# every time the interval is reached.
# reload_interval: 10s
# Backoff strategy configuration used to reconnect to the controller
backoff:
# this is the default type of the backoff strategy,
type: exponential
# the reconnection base delay in milliseconds
base: 500
# the reconnection factor determines how fast the delay increases
factor: 1
# the maximum delay between reconnection attempts in milliseconds
max_delay: 1500
# whether to apply jitter to the backoff delay
jitter: true