0
  string source = string.IsNullOrEmpty(this.logger.PStore[Constants.CurrentKey]) ? "NA" : this.logger.PStore[Constants.CurrentKey];
  string cId = string.IsNullOrEmpty(this.logger.Store[Constants.CId]) ? "NA" : this.logger.Store[Constants.CId];


public virtual void GetMetric(string metricId, double metricValue, string source = "", string cId = "")
    {
        Metric metric = this.TelemetryClient.GetMetric(metricId, "Source", "CorrelationId");
        metric.TrackValue(metricValue, source, cId);
    }
      

The above code I am using to log data in app insight.GetMetric has 2 dimensions along with a metricId and Track value has value along with dimension.

Microsoft.ApplicationInsights, Version=2.17.0.146

n1k1
  • 51
  • 6
  • I cannot reproduce this, not even using the same exact version you do. – Peter Bons Oct 01 '21 at 10:44
  • @PeterBons The version that I have used is 2.10.0..but somehow that shows up in logs..and are you able to see this in the azure app insights log? – n1k1 Oct 01 '21 at 14:25

0 Answers0