Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

subscriber: fix incorrect filtering for tracing-log events #344

Merged
merged 3 commits into from Sep 12, 2019

Commits on Sep 12, 2019

  1. subscriber: add test that log events are filtered

    Signed-off-by: Eliza Weisman <eliza@buoyant.io>
    hawkw committed Sep 12, 2019
    Copy the full SHA
    720da46 View commit details
    Browse the repository at this point in the history
  2. subscriber: fall back to checking statics in enabled

    Currently, the `tracing-subscriber` `EnvFilter` does not properly enable
    events that originate from the `tracing-log` `LogTracer` adapter. This
    is because those events are supposed to be filtered only by `enabled`,
    and will not generate proper `register_callsite` metadata. `EnvFilter`'s
    `enabled` method will assume that an event was not enabled statically,
    since `enabled` wouldn't have been called if the callsite was given the
    `Always` interest. However, this doesn't take `tracing-log` into
    account.
    
    I've changed `EnvFilter` to always check against static filters in
    `enabled` if the dynamic filters don't enable a given metadata. This
    fixes the filtering of `tracing-log` events. I've also added tests that
    fail against the current master.
    
    Signed-off-by: Eliza Weisman <eliza@buoyant.io>
    hawkw committed Sep 12, 2019
    Copy the full SHA
    422e5c1 View commit details
    Browse the repository at this point in the history
  3. rustfmt

    Signed-off-by: Eliza Weisman <eliza@buoyant.io>
    hawkw committed Sep 12, 2019
    Copy the full SHA
    796fc16 View commit details
    Browse the repository at this point in the history