You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 12, 2022. It is now read-only.
I use the TelemetryClient to log pageviews. I see pageviews and traces from nlog in my appinsights. What I want now is to provide the user_id and the session_id in each trace but I do not know how to set this up? the pageviews have a user/session id already.
thanks
The text was updated successfully, but these errors were encountered:
Another way you can try is to implement your own Telemetry Initializer and assign required properties on the outgoing telemetry. Chances are that TelemetryClient used in NLog adapter is actually created with TelemetryConfiguration.Active as a configuration, so any initializer you add into applicationinsights.config should be executed for those traces. This is more-less generic AI approach on adding custom properties to the outgoing item.
snakefoot's suggestion, however, seems to be right approach from NLog view on this - you simply expose/propagate the properties you care about.
I have nlog logging to appinsights. it is configured in the app.config without any keys.
in the program startup I call:
I use the TelemetryClient to log pageviews. I see pageviews and traces from nlog in my appinsights. What I want now is to provide the user_id and the session_id in each trace but I do not know how to set this up? the pageviews have a user/session id already.
thanks
The text was updated successfully, but these errors were encountered: