You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+23-11Lines changed: 23 additions & 11 deletions
Original file line number
Diff line number
Diff line change
@@ -110,9 +110,9 @@ This setting is independent from `LUMIGO_DEBUG`, that is, `LUMIGO_DEBUG` does no
110
110
*`LUMIGO_SECRET_MASKING_REGEX_HTTP_RESPONSE_BODIES` applies secret redaction to HTTP response bodies
111
111
*`LUMIGO_SECRET_MASKING_REGEX_HTTP_RESPONSE_HEADERS` applies secret redaction to HTTP response bodies
112
112
*`LUMIGO_SECRET_MASKING_REGEX_ENVIRONMENT` applies secret redaction to process environment variables (that is, the content of `process.env`)
113
-
*`LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX='["regex1", "regex2"]'`: This option enables the filtering of client and server endpoints that match the supplied regular expressions. More fine-grained settings can be applied via the following environment variables, which will work in addition to`LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX` for a specific span type:
114
-
*`LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX_SERVER` applies the filter to server spans only. Matching is performed against the following attributes on a span: `url.path`, and `http.target`.
115
-
*`LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX_CLIENT` applies the filter to client spans only. Matching is performed against the following attributes on a span: `url.full`, and `http.url`.
113
+
*`LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX='["regex1", "regex2"]'`: This option enables the filtering of client and server endpoints through regular expression searches. Fine-tune your settings via the following environment variables, which work in conjunction with`LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX` for a specific span type:
114
+
*`LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX_SERVER` applies the regular expression search exclusively to server spans. Searching is performed against the following attributes on a span: `url.path` and `http.target`.
115
+
*`LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX_CLIENT` applies the regular expression search exclusively to client spans. Searching is performed against the following attributes on a span: `url.full` and `http.url`.
116
116
117
117
For more information check out [Filtering http endpoints](#filtering-http-endpoints).
118
118
@@ -468,18 +468,30 @@ The possible variations are (case-insensitive):
468
468
469
469
### Filtering http endpoints
470
470
471
-
It is possible to filter out spans based on the HTTP server / client endpoints for all supported web server frameworks.
471
+
You can selectively filter spans based on HTTP server/client endpoints for various components, not limited to web frameworks.
472
472
473
-
Set the `LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX` environment variable to a list of regex strings that will match
474
-
server / client endpoints.
475
-
Spans with matching endpoints will be not be traced.
476
-
If you only want to filter out server (inbound) spans or client (outbound) spans, you can set the env vars
477
-
`LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX_SERVER` or `LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX_CLIENT` respectively.
473
+
#### Global filtering
474
+
Set the `LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX` environment variable to a list of regex strings. Spans with matching server/client endpoints will not be traced.
478
475
479
-
If we are filtering out an HTTP call to an opentelemetry traced component, every subsequent invocation made by that
476
+
#### Specific Filtering
477
+
For exclusive server (inbound) or client (outbound) span filtering, use the environment variables:
478
+
* `LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX_SERVER`
479
+
* `LUMIGO_FILTER_HTTP_ENDPOINTS_REGEX_CLIENT`
480
+
481
+
Notes:
482
+
* the environment variable must be a valid JSON array of strings, so if you want to match endpoint with the hostname `google.com` the environment variable value should be `["google\\.com"]`.
483
+
* If we are filtering out an HTTP call to an opentelemetry traced component, every subsequent invocation made by that
480
484
component won't be traced either.
481
485
482
-
When filtering out an HTTP span, all child spans will not be recorded as well.
486
+
Examples:
487
+
* Filtering out every incoming HTTP request to the `/login` endpoint (will also match requests such as `/login?user=foo`, `/login/bar`))):
* Filtering out every outgoing HTTP request to `https://www.google.com` (will also match requests such as `https://www.google.com/`, `https://www.google.com/foo`)
0 commit comments