fix: make instrumentation optional#6449
Conversation
Allows to stop instrumenting functions which prevents from massive log entries due to logged structures.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6449 +/- ##
==========================================
- Coverage 89.82% 89.46% -0.37%
==========================================
Files 378 378
Lines 104337 107974 +3637
Branches 104337 107974 +3637
==========================================
+ Hits 93724 96601 +2877
- Misses 7015 7456 +441
- Partials 3598 3917 +319 ☔ View full report in Codecov by Sentry. |
Merging this PR will degrade performance by 49.52%
|
| Mode | Benchmark | BASE |
HEAD |
Efficiency | |
|---|---|---|---|---|---|
| ❌ | Simulation | Restore session [memory store] |
112.8 ms | 223.4 ms | -49.52% |
Comparing panekj:pj/gate-tracing-instrument (988c820) with main (dab87b7)
bnjbvr
left a comment
There was a problem hiding this comment.
Thanks, looks like this is on the right track!
Let's make sure to publicize the change by indicating in the CHANGELOG.mds of each of the touched crates that instrumentation is now disabled by default, and can be re-enabled with the Cargo feature.
Also, we'd probably want to enable it on one of the CI tasks, at least, and make sure it's enabled when building the UniFFI bindings: we could either enable the instrument features for the matrix-sdk-ffi crate by default (?), or include it manually for the swift and kotlin bindings generation tasks in the xtask helper.
Fixes #6254
CHANGELOG.mdfiles.Signed-off-by: