-
Notifications
You must be signed in to change notification settings - Fork 1
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
NH-34752 Parse txn filters and calculate tracing mode #136
NH-34752 Parse txn filters and calculate tracing mode #136
Conversation
solarwinds_apm/apm_config.py
Outdated
continue | ||
|
||
try: | ||
re.compile(filter["regex"]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since you're already compiling the regex in here wouldn't it make sense to store the result in txn_filter
so it doesn't have to get recompiled on every match
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea! Changed in d28c040.
41dfe72
to
336b89a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good !
This is more steps towards implementing transaction filtering:
update_transaction_filters
in the Configurator to use existing helperOboeTracingMode.get_oboe_trace_mode
to map filter'stracing
to int for liboboeregex
valuescalculate_tracing_mode
used by sampler to apply per-request filter or "global"tracing_mode
that can also be configured.This only filters for span
<kind>:<name>
right now becausehttp.*
attributes generated by instrumentation libraries are not yet available to the sampler, but this is gradually being implemented in OTel #936.Example basic config file JSON I'm using with Django A:
Next PRs:
OR support for third filter component, signal (see Slack thread)See NH-34752 Add construct_url for calculate_tracing_mode #137Please let me know if any questions/suggestions!