This repository has been archived by the owner on Jul 5, 2020. It is now read-only.
This repository has been archived by the owner on Jul 5, 2020. It is now read-only.
Support reading metadata when collecting EventCounter data #1287
Closed
Description
openedon Oct 7, 2019
Regarding the (new) Microsoft.ApplicationInsights.EventCounterCollector:
When I define a custom EventCounter
I can add metadata to it:
methodDurationCounter = new EventCounter(nameof(methodDurationCounter), this);
methodDurationCounter.AddMetadata("Environment", "Production");
methodDurationCounter.AddMetadata("Customer", "Ibis");
This metadata is added to the payload. I would be very happy when this data is included as custom properties of the MetricTelemetry that is send. See the source.
I would be more than willing to provide a PR for this.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment