Skip to content
Snippets Groups Projects
  1. Jul 05, 2021
  2. May 31, 2021
    • Georges Racinet's avatar
      CommitService logging all incoming requests · dcef6bbdc59a
      Georges Racinet authored
      In some cases this replaces existing logs with the more complete
      dump of the request.
      
      Again, it's not useful to put the name of the method in the message:
      the name of the request class fulfills that purpose easily.
      dcef6bbdc59a
    • Georges Racinet's avatar
      RefService logging all incoming requests · 06e62bed644b
      Georges Racinet authored
      We don't need to include the method name in the log message,
      because of the Gitaly protocol conventions: each method has
      its own, dedicated Request class, whose name is already part of
      the rendering.
      06e62bed644b
  3. Jul 01, 2021
  4. Mar 21, 2021
  5. Mar 20, 2021
  6. Jun 17, 2021
  7. Jun 16, 2021
  8. May 26, 2021
  9. Mar 25, 2021
  10. Mar 23, 2021
  11. May 25, 2021
  12. Apr 04, 2021
    • Georges Racinet's avatar
      message: wrapper class for easy logging · 10be0d6ac733
      Georges Racinet authored
      With gRPC, the `repr` of messages, notably Gitaly Requests
      is made of multiple lines.
      This is very bad for logging: a log should always be made of
      a single line for:
      
      - meaningful grepping
      - detangling when several processes log to the same file
      
      We want in particular service method to be able to log
      easily their incoming requests and/or more messages, but
      we want the formatting to be done only if the log is
      actually to be emitted (important to avoid debug logs to
      make production servers choke). This is usually achieved with
      the following pattern, because logging evaluation is inherently
      lazy.
      
      ```python
      logging.debug('the interesting object is %r', obj)
      ```
      
      We could use extras, as `hg-loggingmod` does for the repository,
      but that is evaluated in the final formatting of the entire log
      line, and requires to register a specific format, then a specific
      handler to use it.
      
      The provided solution (wrapping in a class), is not zero-cost,
      but is expected to be cheap enough for the time being.
      10be0d6ac733
  13. May 18, 2021
  14. Apr 25, 2021
  15. Apr 24, 2021
  16. Apr 22, 2021
  17. Apr 11, 2021
Loading