[#470] grpc: Increase message limits
All checks were successful
Build / Build Components (1.19) (pull_request) Successful in 3m27s
ci/woodpecker/pr/pre-commit Pipeline was successful
Build / Build Components (1.20) (pull_request) Successful in 3m25s
Tests and linters / Lint (pull_request) Successful in 2m15s
Tests and linters / Tests (1.19) (pull_request) Successful in 2m51s
Tests and linters / Tests (1.20) (pull_request) Successful in 5m54s
Tests and linters / Tests with -race (pull_request) Successful in 6m31s
ci/woodpecker/push/pre-commit Pipeline was successful
All checks were successful
Build / Build Components (1.19) (pull_request) Successful in 3m27s
ci/woodpecker/pr/pre-commit Pipeline was successful
Build / Build Components (1.20) (pull_request) Successful in 3m25s
Tests and linters / Lint (pull_request) Successful in 2m15s
Tests and linters / Tests (1.19) (pull_request) Successful in 2m51s
Tests and linters / Tests (1.20) (pull_request) Successful in 5m54s
Tests and linters / Tests with -race (pull_request) Successful in 6m31s
ci/woodpecker/push/pre-commit Pipeline was successful
For send message limit set to 2GiB, but there are custom GET/GET RANGE limiters. For receive message limit set to 256 MiB, but actual chunk size will be managed by client. Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
parent
f437ab8f15
commit
0c5b025788
1 changed files with 3 additions and 1 deletions
|
@ -17,11 +17,13 @@ import (
|
||||||
"google.golang.org/grpc/credentials"
|
"google.golang.org/grpc/credentials"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
const maxRecvMsgSize = 256 << 20
|
||||||
|
|
||||||
func initGRPC(c *cfg) {
|
func initGRPC(c *cfg) {
|
||||||
var successCount int
|
var successCount int
|
||||||
grpcconfig.IterateEndpoints(c.appCfg, func(sc *grpcconfig.Config) {
|
grpcconfig.IterateEndpoints(c.appCfg, func(sc *grpcconfig.Config) {
|
||||||
serverOpts := []grpc.ServerOption{
|
serverOpts := []grpc.ServerOption{
|
||||||
grpc.MaxSendMsgSize(maxMsgSize),
|
grpc.MaxRecvMsgSize(maxRecvMsgSize),
|
||||||
grpc.ChainUnaryInterceptor(
|
grpc.ChainUnaryInterceptor(
|
||||||
metrics.NewUnaryServerInterceptor(),
|
metrics.NewUnaryServerInterceptor(),
|
||||||
tracing.NewUnaryServerInterceptor(),
|
tracing.NewUnaryServerInterceptor(),
|
||||||
|
|
Loading…
Reference in a new issue