dcelasun commented on pull request #1992:
URL: https://github.com/apache/thrift/pull/1992#issuecomment-705791654


   > I'm not so sure how important it is to log all requests/responses for 
every request.
   
   Agreed. In my experience this is only needed rarely for debugging and when 
that happens something like this works just fine inside the handler:
   ```go
   func (s *Server) ExampleHandler(ctx context.Context, req 
*gen.ExampleRequest) (resp *gen.ExampleResponse, respErr error) {
        t := trace.New(ctx, "example").Input(req)
        defer func() { t.Output(resp, respErr).Send() }()
        
        // rest of the handler code...
   }
   ```
   
   So yeah, I think the cost of this change is way too high to avoid those 2 
lines of code. 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to