Skip to content
This repository was archived by the owner on Feb 3, 2022. It is now read-only.

Commit

Permalink
upd(schema): schema2.0 updated and support full .rr.yaml configuration
Browse files Browse the repository at this point in the history
Signed-off-by: Valery Piashchynski <[email protected]>
  • Loading branch information
rustatian committed Dec 7, 2021
1 parent 67621f9 commit 4813341
Show file tree
Hide file tree
Showing 2 changed files with 100 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .rr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1255,7 +1255,7 @@ grpc:
# Client auth type
#
# This option is optional. Default value: no_client_certs. Possible values: request_client_cert, require_any_client_cert, verify_client_cert_if_given, require_and_verify_client_cert, no_client_certs
client_auth_type: ""
client_auth_type: "no_client_certs"

# Maximum send message size
#
Expand Down Expand Up @@ -1285,7 +1285,7 @@ grpc:

# MaxConnectionAgeGrace is an additive period after MaxConnectionAge after
# which the connection will be forcibly closed.
max_connection_age_grace: 0s
max_connection_age_grace: 0s8h

# MaxConnectionAgeGrace is an additive period after MaxConnectionAge after
# which the connection will be forcibly closed.
Expand Down
98 changes: 98 additions & 0 deletions schemas/config/2.0.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1284,6 +1284,96 @@
}
}
},
"grpc": {
"description": "GRPC plugin",
"type": "object",
"properties": {
"listen": {
"description": "GRPC address to listen",
"type": "string",
"$ref": "#/definitions/HostAndPortWithTCP"
},
"proto": {
"type": "array",
"description": "Proto file to use, multiply files supported [SINCE 2.6]",
"items": {
"type": "string"
}
},
"tls": {
"description": "GRPC TLS configuration",
"type": "object",
"properties": {
"key": {
"description": "Path to the key file",
"type": "string",
"default": null
},
"cert": {
"description": "Path to the certificate",
"type": "string",
"default": null
},
"root_ca": {
"description": "Path to the CA certificate",
"type": "string",
"default": null
},
"client_auth_type": {
"description": "Client auth type",
"type": "string",
"default": "no_client_certs",
"enum": [
"request_client_cert",
"require_any_client_cert",
"verify_client_cert_if_given",
"no_client_certs"
]
}
}
},
"max_send_msg_size": {
"type": "integer",
"description": "Maximum send message size",
"default": 50
},
"max_recv_msg_size": {
"description": "Maximum receive message size",
"default": 50,
"type": "integer"
},
"max_connection_idle": {
"description": " MaxConnectionIdle is a duration for the amount of time after which an idle connection would be closed by sending a GoAway. Idleness duration is defined since the most recent time the number of outstanding RPCs became zero or the connection establishment",
"$ref": "#/definitions/Duration"
},
"max_connection_age": {
"description": "MaxConnectionAge is a duration for the maximum amount of time a connection may exist before it will be closed by sending a GoAway. A random jitter of +/-10% will be added to MaxConnectionAge to spread out connection storms",
"$ref": "#/definitions/Duration"
},
"max_connection_age_grace": {
"description": "MaxConnectionAgeGrace is an additive period after MaxConnectionAge after which the connection will be forcibly closed",
"$ref": "#/definitions/Duration"
},
"max_concurrent_streams": {
"description": "MaxConnectionAgeGrace is an additive period after MaxConnectionAge after which the connection will be forcibly closed",
"type": "integer",
"default": 10
},
"ping_time": {
"description": "After a duration of this time if the server doesn't see any activity it pings the client to see if the transport is still alive. If set below 1s, a minimum value of 1s will be used instead",
"$ref": "#/definitions/Duration"
},
"timeout": {
"description": "After having pinged for keepalive check, the server waits for a duration of Timeout and if no activity is seen even after that the connection is closed",
"$ref": "#/definitions/Duration"
},
"pool": {
"description": "GRPC workers pool",
"type": "object",
"$ref": "#/definitions/WorkersPool"
}
}
},
"fileserver": {
"description": "[SINCE 2.6] File server to serve static files",
"type": "object",
Expand Down Expand Up @@ -1624,6 +1714,14 @@
}
]
},
"HostAndPortWithTCP": {
"description": "Host and port with tcp:// prefix",
"type": "string",
"pattern": "^(tcp://[0-9a-zA-Z_.-]+|):[0-9]{1,5}$",
"examples": [
"tcp://127.0.0.1:443"
]
},
"HostAndPort": {
"description": "Host and port",
"type": "string",
Expand Down

0 comments on commit 4813341

Please sign in to comment.