chore: refactor zrpc timeout (#3671)
This commit is contained in:
@@ -131,12 +131,8 @@ func setupInterceptors(svr internal.Server, c RpcServerConf, metrics *stat.Metri
|
||||
}
|
||||
|
||||
if c.Timeout > 0 {
|
||||
svr.AddUnaryInterceptors(
|
||||
serverinterceptors.UnaryTimeoutInterceptor(
|
||||
time.Duration(c.Timeout)*time.Millisecond,
|
||||
c.SpecifiedTimeouts...,
|
||||
),
|
||||
)
|
||||
svr.AddUnaryInterceptors(serverinterceptors.UnaryTimeoutInterceptor(
|
||||
time.Duration(c.Timeout)*time.Millisecond, c.MethodTimeouts...))
|
||||
}
|
||||
|
||||
if c.Auth {
|
||||
|
||||
Reference in New Issue
Block a user