我正在将 Azure Application Insight 服务集成到我的 Spring Boot 应用程序中。
applicationinsights.json
下的src/main/resources
用于配置。不确定如何将环境变量注入applicationinsights.json
。
我试过这个
applicationinsights.json
{
"connectionString": "InstrumentationKey=${appInsightInstrumentationKey};IngestionEndpoint=https://eastus-8.in.applicationinsights.azure.com/;LiveEndpoint=https://eastus.livediagnostics.monitor.azure.com/"
}
其中
appInsightInstrumentationKey
来自KeyVault并且可用。
这会引发错误
路径中的非法字符 在 java.base/java.net.URI.create(URI.java:883) 在 reactor.netty.http.HttpOperations.resolvePath(HttpOperations.java:429)
感谢您的帮助。