Currently interceptors in c# are invoked after deserializing the request and before serializing the response, so if you can't really deserialize the response, interceptors won't work for you.
One option would be to setup a "generic" handler that accepts the raw payload instead of protobuf messages, but then you would be responsible for (de)serializing the protobufs yourself (which seems clumsy). You could perhaps also use some kind of proxy (Envoy?) that could log the requests for you. On Tue, Jun 4, 2019 at 9:20 AM Krzysiek <[email protected]> wrote: > > hi, > > Is it possible to log all traffic incoming to the server via interceptor ? > > I run Grpc server, but my client sometimes change "proto" contracts > (because he's cooperating with other companies and usually "forget" to > inform us). > I have implemented interceptor (using C# Grpc.Core.Interceptors > UnaryServerHandler) to log requests, but it won't work for those endpoints > that are not in my version of contract. > > thanks, > Krzysiek > > -- > You received this message because you are subscribed to the Google Groups " > grpc.io" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/grpc-io/d817f4de-7c5b-411e-8f29-761af336351c%40googlegroups.com > <https://groups.google.com/d/msgid/grpc-io/d817f4de-7c5b-411e-8f29-761af336351c%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- Jan -- You received this message because you are subscribed to the Google Groups "grpc.io" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/grpc-io/CACF4M0T7_OJcPP4ZqMnt-Rqj%3D-pcn6abAumTGBRmZYbQdc%3DWfw%40mail.gmail.com.
smime.p7s
Description: S/MIME Cryptographic Signature
