grapl-security / grapl

Graph platform for Detection and Response
https://www.graplsecurity.com
Apache License 2.0
686 stars 78 forks source link

Universal server tracing function #2105

Closed wimax-grapl closed 2 years ago

wimax-grapl commented 2 years ago

Previously we had the same trace logic repeated over and over again - and worse, it usually included the full headers which contains all sorts of useless fields that clog up logging. (also uri is mostly useless when method is included).

So now I just do request id and trace id.

Don't worry - services can, in the future, specify addl trace fns if they really want to!

wimax-grapl commented 2 years ago

Abandoning because

  1. we don't want each span to have the same name or they'll all get bucketed together
  2. info_span! expects a const, unfortunately, so you gotta specify it there it can't be passed in