refactoring tracing interceptors. (#1009)
* refactor tracing interceptors * add stream tracing interceptor
This commit is contained in:
@@ -55,6 +55,7 @@ func (s *rpcServer) Start(register RegisterFn) error {
|
||||
|
||||
unaryInterceptors := []grpc.UnaryServerInterceptor{
|
||||
serverinterceptors.UnaryTracingInterceptor(s.name),
|
||||
serverinterceptors.UnaryOpenTracingInterceptor(),
|
||||
serverinterceptors.UnaryCrashInterceptor(),
|
||||
serverinterceptors.UnaryStatInterceptor(s.metrics),
|
||||
serverinterceptors.UnaryPrometheusInterceptor(),
|
||||
@@ -62,6 +63,8 @@ func (s *rpcServer) Start(register RegisterFn) error {
|
||||
}
|
||||
unaryInterceptors = append(unaryInterceptors, s.unaryInterceptors...)
|
||||
streamInterceptors := []grpc.StreamServerInterceptor{
|
||||
serverinterceptors.StreamTracingInterceptor(s.name),
|
||||
serverinterceptors.StreamOpenTracingInterceptor(),
|
||||
serverinterceptors.StreamCrashInterceptor,
|
||||
serverinterceptors.StreamBreakerInterceptor,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user