diff options
author | David Baker <dave@matrix.org> | 2016-05-10 14:40:19 +0200 |
---|---|---|
committer | David Baker <dave@matrix.org> | 2016-05-10 14:40:19 +0200 |
commit | 997db0464828c8e8eac7dfa055f4fcd25e89cd29 (patch) | |
tree | d10252566e9bc96a9bdf95bcd37e4db4ead6ab62 /docs | |
parent | More consistent config naming (diff) | |
parent | Merge pull request #773 from matrix-org/erikj/get_domian_from_id (diff) | |
download | synapse-997db0464828c8e8eac7dfa055f4fcd25e89cd29.tar.xz |
Merge remote-tracking branch 'origin/develop' into dbkr/email_notifs
Diffstat (limited to 'docs')
-rw-r--r-- | docs/log_contexts.rst | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/docs/log_contexts.rst b/docs/log_contexts.rst new file mode 100644 index 0000000000..0046e171be --- /dev/null +++ b/docs/log_contexts.rst @@ -0,0 +1,10 @@ +What do I do about "Unexpected logging context" debug log-lines everywhere? + +<Mjark> The logging context lives in thread local storage +<Mjark> Sometimes it gets out of sync with what it should actually be, usually because something scheduled something to run on the reactor without preserving the logging context. +<Matthew> what is the impact of it getting out of sync? and how and when should we preserve log context? +<Mjark> The impact is that some of the CPU and database metrics will be under-reported, and some log lines will be mis-attributed. +<Mjark> It should happen auto-magically in all the APIs that do IO or otherwise defer to the reactor. +<Erik> Mjark: the other place is if we branch, e.g. using defer.gatherResults + +Unanswered: how and when should we preserve log context? \ No newline at end of file |