microsoft / ApplicationInsights-node.js

Microsoft Application Insights SDK for Node.js
MIT License
321 stars 138 forks source link

Upgrade 2.x to 3.0.1 startup warnings #1324

Open skhilliard opened 1 month ago

skhilliard commented 1 month ago

Upgrading from 2.x to 3.0.1 I am seeing some warnings logged that look a little worrysome...

@azure/opentelemetry-instrumentation-azure-sdk [
  'Module @azure/core-tracing has been loaded before @azure/opentelemetry-instrumentation-azure-sdk so it might not work, please initialize it before requiring @azure/core-tracing'
]```

and 

Accessing resource attributes before async attributes settled []



...are these of concern?  If so, how can they be fixed?
JacksonWeber commented 1 month ago

Regarding the first warning: https://github.com/microsoft/ApplicationInsights-node.js/issues/1316. Looking into resolving this with the Azure SDK libraries throwing the warning.

The async attributes settled warning is thrown by OpenTelemetry and occurs because we populate resource attributes asynchronously when trying to determine if the application is running in a VM environment. We are also looking into ways to mitigate this warning as well.

skhilliard commented 1 month ago

@JacksonWeber Any updates for this? Thanks!

rassiju06 commented 1 month ago

I have the same issue.

JacksonWeber commented 4 weeks ago

@skhilliard @rassiju06 As of 3.1.0 the warnings surrounding performance counter metrics are resolved, however the warnings surrounding package loading and resource attributes are not. Please refer to https://github.com/microsoft/ApplicationInsights-node.js/issues/1107 if you're looking to suppress these warnings.