-
Notifications
You must be signed in to change notification settings - Fork 201
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
Feature request: keep all InProc dependencies via sampling overrides #4016
Comments
BackgroundApplication Insights allows to blacklist dependencies - spans with the INTERNAL, PRODUCER, CLIENT and so on types, i.e. exclude the unnecessary ones and keep the necessary ones. There is no problem with this. {
"sampling": {
"percentage": 100,
"overrides": [
{
"telemetryType": "dependency",
"attributes": [
{
"key": "db.system",
"value": "redis",
"matchType": "strict"
}
],
"percentage": 0
}
]
}
} If the client wants to maintain a whitelist of dependencies, there may be a problem with span with the INTERNAL kind (InProc type). They can be created using the For example, when using the following configuration: {
"preview": {
"captureControllerSpans": true // https://learn.microsoft.com/en-us/azure/azure-monitor/app/java-standalone-config#autocollect-inproc-dependencies-preview
},
"sampling": {
"percentage": 0,
"overrides": [
{
"telemetryType": "dependency",
"attributes": [
{
"key": "db.system",
"value": "redis",
"matchType": "strict"
}
],
"percentage": 100
}
]
}
} Redis dependencies will be preserved, all others including custom/user (InProc) will be captured ( P.S. The following configuration will save all spans, not just InProc, which also does not satisfy the whitelist definition. {
"preview": {
"captureControllerSpans": true // https://learn.microsoft.com/en-us/azure/azure-monitor/app/java-standalone-config#autocollect-inproc-dependencies-preview
},
"sampling": {
"percentage": 0,
"overrides": [
{
"telemetryType": "dependency",
"percentage": 100
}
]
}
} |
I think sampling on a percentage basis is not a good solution, as you also pointed out in #3654 (comment).
I think it's better to provide a switch, like "sampling.keepInProcDependencies" or similar, that allows to toggle keep or exclude InProc dependencies. But in this case, it's necessary to make sure that if the user sets {
"sampling": {
"percentage": 0,
"keepInProcDependencies": false,
"overrides": [
{
"telemetryType": "dependency",
"attributes": [
{
"key": "product",
"value": "test",
"matchType": "strict"
}
],
"percentage": 100
}
]
}
} |
I didn't follow how this is different from providing a new |
For example, to support keeping all Inproc dependencies (INTERNAL spans), but dropping all other dependencies (CLIENT spans).
An option to support this would be to introduce a new
telemetryType
ofdependency/inproc
, e.g.The text was updated successfully, but these errors were encountered: