Applicationinsights-js: Support setting cloud_RoleName property for telemetry to support multi-component monitoring

Created on 27 Sep 2017  路  3Comments  路  Source: microsoft/ApplicationInsights-JS

Is it possible to set the cloud_RoleName property for a client-side telemetry item, similar to what is possible with the server-side SDK (telemetry.Context.Cloud.RoleName)?
We're currently looking into multi-component monitoring (https://docs.microsoft.com/en-us/azure/application-insights/app-insights-monitor-multi-role-apps) but there seems to be no way to assign a role name to client-side telemetry. This messes up the Application Map and overall correlation.

Any help/insights would be appreciated.

question

All 3 comments

Yes, you can create a telemetry initializer to set "ai.device.roleName" tag on each envelope.

Please use ai.cloud.roleName, not device

Thanks for pointing me in the right direction guys! I ended up using ai.cloud.role (https://stackoverflow.com/a/45417851/1662317) after I found that neither ai.cloud.roleName nor ai.device.roleName seemed to be working.

Thanks again!

Was this page helpful?
0 / 5 - 0 ratings