Skip to content
Snippets Groups Projects
  1. Dec 13, 2012
    • Iustin Pop's avatar
      Log only partial response in Luxi when in debug mode · f74b88fa
      Iustin Pop authored
      
      Currently, we log the entire response (at debug level) in the Luxi
      replies. This is not a good idea; the logging library operates on
      strings, and as such it will use huge amounts of memory: without debug
      logging, a certain gnt-job list invocation uses 295MB (+RTS -s) and
      2m35s time, when in debug mode, it's 1525MB and 48m!
      
      So we make two changes:
      
      - first, we switch from "show (pp_value a)" to "encode a", which
        generates a non-formatted string rather than a indented one
      - second we log only the first 2000 characters; this should be enough
        to understand the first part of the response
      
      We could go for higher, or for logging in batches (that would be
      faster, as well).
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarHelga Velroyen <helgav@google.com>
      f74b88fa
  2. Dec 12, 2012
  3. Dec 11, 2012
  4. Dec 10, 2012
  5. Dec 07, 2012
  6. Dec 06, 2012
  7. Dec 05, 2012
  8. Dec 04, 2012
  9. Dec 03, 2012
Loading