ApplicationInsightsRiderPlugin icon indicating copy to clipboard operation
ApplicationInsightsRiderPlugin copied to clipboard

Support pageview/screenview events

Open snechaev opened this issue 10 months ago • 0 comments

https://github.com/Socolin/ApplicationInsightsRiderPlugin/blob/1976bba60df3ad4e2affc58b585a892914de86b5/src/main/java/fr/socolin/applicationinsights/TelemetryType.java#L6-L13

When developing the desktop application, the "Screen/Page View" events are used extensively (which are tracked with the TelemetryClient.TrackPageView()).

Currently, the plugin can't recognize this event and display the screen name on the Formatted tab. It shows such an event as "Unk - fr.socolin.applicationinsights.Telemetry@7a789271"

The raw content of the event looks like this

{
	"name": "AppPageViews",
	"time": "2024-04-18T17:40:50.9463710Z",
	"iKey": "598b75d8-......",
	"tags": {
		"ai.application.ver": "23.1.3.0",
		"ai.device.osVersion": "Unix 14.4.1",
		"ai.cloud.roleInstance": "imac",
		"ai.session.id": "9b6183fa-...",
		"ai.user.id": "2ad5af43-...",
		"ai.internal.sdkVersion": "dotnetc:2.22.0-997"
	},
	"data": {
		"baseType": "PageViewData",
		"baseData": {
			"ver": 2,
			"name": "my app specific screen name, passed in the TelemetryClient.TrackPageView()",
			"duration": "00:00:00",
			"properties": {
				"ProcessorCount": "6",
				"DeveloperMode": "true",
				"ClrVersion": "6.0.29"
			}
		}
	}
}

The main point of interest (to show on the Formatted tab) in this event are following

  • the screen name - \data\baseData\name
  • duration - \data\baseData\duration

P.S. Many thanks for the great plugin!

snechaev avatar Apr 18 '24 17:04 snechaev