ApplicationInsights-Java
ApplicationInsights-Java copied to clipboard
APPLICATIONINSIGHTS_CONFIGURATION_CONTENT will not be considered in Azure Functions
Expected behavior
Content of environment variable APPLICATIONINSIGHTS_CONFIGURATION_CONTENT is considered by application insights agent
Actual behavior
We are using a quarkus framework to create and run our Azure Function. We set the application insights setting "Collection level" to Recommended so that the application insights agent is automatically added. Because vertx communication is not visible in the Application Insights we would like to enable it via entry in applicationinsights.json
{
"preview":{
"instrumentation":{
"vertx":{
"enabled":true
}
}
}
}
we provided the content via environment variable APPLICATIONINSIGHTS_CONFIGURATION_CONTENT, but the issue is still present. We added some more configuration to APPLICATIONINSIGHTS_CONFIGURATION_CONTENT, but it seems that this doesn't have any effect. Even if the content is not a valid json, nothing happens (even no logs).
To Reproduce
- create quarkus application
- deploy the application
- set the "Collection level" to Recommended
- set environment variable APPLICATIONINSIGHTS_CONFIGURATION_CONTENT with some content
System information
Please provide the following information:
- Quarkus 3.11.1 it uses azure-functions-java-library 3.1.0
- Java 17
- Azure Function OS: Linux
- Azure Function Runtime version: 4.34.2.2
- Used application insights agent version: ?? is not printed in the log