Add TwirpRequestStatusReporter twirp server hook to count requests (#1309)

This commit is contained in:
Benjamin Pracht
2023-01-18 11:53:20 -08:00
committed by GitHub
parent bccf7a6842
commit edc39da0b1
7 changed files with 120 additions and 25 deletions
+2 -1
View File
@@ -83,8 +83,9 @@ func NewLivekitServer(conf *config.Config,
}
twirpLoggingHook := TwirpLogger(logger.GetLogger())
twirpRequestStatusHook := TwirpRequestStatusReporter()
roomServer := livekit.NewRoomServiceServer(roomService, twirpLoggingHook)
egressServer := livekit.NewEgressServer(egressService, twirpLoggingHook)
egressServer := livekit.NewEgressServer(egressService, twirpLoggingHook, twirpRequestStatusHook)
ingressServer := livekit.NewIngressServer(ingressService, twirpLoggingHook)
mux := http.NewServeMux()