Skip to content
This repository has been archived by the owner on Jun 2, 2024. It is now read-only.
This repository has been archived by the owner on Jun 2, 2024. It is now read-only.

Tag call.http.header is independent of source or destination #137

Closed
valentinvladimir opened this issue Aug 22, 2022 · 2 comments
Closed

Comments

@valentinvladimir
Copy link

valentinvladimir commented Aug 22, 2022

First of all, thank you for this provider!

Issue: Filtering based on a http header attribute can not be configured anymore.

terraform code:
"
resource "instana_application_config" "this" {
...
tag_filter = "kubernetes.cluster.name EQUALS 'this' AND kubernetes.namespace EQUALS 'namespace' AND kubernetes.deployment.name EQUALS 'microservice' AND call.http.header:vf-country-code EQUALS 'PT'"
}
"

terraform plan:

~ tag_filter = "kubernetes.cluster.name@dest EQUALS 'this' AND kubernetes.namespace@dest EQUALS 'namespace' AND kubernetes.deployment.name@dest EQUALS 'microservice' -> "kubernetes.cluster.name@dest EQUALS 'this' AND kubernetes.namespace@dest EQUALS 'namespace' AND kubernetes.deployment.name@dest EQUALS 'microservice' AND call.http.header:vf-country-code@dest EQUALS 'PT'"

Error: "code":422,"message":"Tag call.http.header is independent of source or destination"

So the issue is @ dest after call.http.header:vf-country-code

The reply from Instana is:

"
There were some improvements in release 228:
• Improved the validation of stored tag-filters in various areas such as SmartAlerts, Application Perspectives and Service Level Objectives (SLOs):
• Improved the error messages to include more details about the exact problem when invalid tag-filters are provided.
• Invalid tag-filters are now rejected.

So, unfortunately, you won't be able to use this API call syntax anymore for Application Perspective.
"

@gessnerfl
Copy link
Owner

@valentinvladimir I need to check this in more detail how I can address this issue.
For now as a workaround you can explicitly set the entity origin to na:

tag_filter = "kubernetes.cluster.name EQUALS 'this' AND kubernetes.namespace EQUALS 'namespace' AND kubernetes.deployment.name EQUALS 'microservice' AND call.http.header@na EQUALS 'vf-country-code=PT'"

@gessnerfl
Copy link
Owner

@valentinvladimir:
Currently there is no API available which would allow to get this information from instana. Because of this it is required to properly set the entity origin when defining a resource.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants