Skip to content

Filter/Sample requests based on captured header value via app insights config using sampling override feature #2285

Closed
@kaynat12

Description

@kaynat12

Is your feature request related to a problem? Please describe.
I am using 3.2.11 app insights agent and could capture header values as below in config file,

"preview": {
"captureHttpServerHeaders": {
"requestHeaders": [ "test"] }

I could see that values are stored under custom dimensions as http.request.header.test in requests table

I want to filter out the requests with header 'test' value as true. I tried sampling as below but doesn't seems to work
"sampling": {
"overrides": [{
"attributes": [ {
"key": "http.request.header.test",
"value": "true",
"matchType": "strict"}],
"percentage": 0
}
I tried with key as customDimensions.["http.request.header.test"] also, still same issue.

Describe the solution you would like

  1. Need to have a feature to filter requests based on header value via sampling or possible attribute key for it.
  2. Any other alternative if above is not possible

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions