@@ -432,7 +432,7 @@ func otelMetricsToTimeseries(ctx context.Context, tenantID string, addSuffixes,
432432// Old, less efficient, version of otelMetricsToTimeseries.
433433func otelMetricsToTimeseriesOld (ctx context.Context , tenantID string , addSuffixes , enableCTZeroIngestion bool , discardedDueToOtelParseError * prometheus.CounterVec , logger log.Logger , md pmetric.Metrics ) ([]mimirpb.PreallocTimeseries , error ) {
434434 converter := prometheusremotewrite .NewPrometheusConverter ()
435- errs := converter .FromMetrics (ctx , md , prometheusremotewrite.Settings {
435+ annots , errs := converter .FromMetrics (ctx , md , prometheusremotewrite.Settings {
436436 AddMetricSuffixes : addSuffixes ,
437437 EnableCreatedTimestampZeroIngestion : enableCTZeroIngestion ,
438438 })
@@ -452,6 +452,10 @@ func otelMetricsToTimeseriesOld(ctx context.Context, tenantID string, addSuffixe
452452
453453 level .Warn (logger ).Log ("msg" , "OTLP parse error" , "err" , parseErrs )
454454 }
455+ ws , _ := annots .AsStrings ("" , 0 , 0 )
456+ if len (ws ) > 0 {
457+ level .Warn (logger ).Log ("msg" , "Warnings translating OTLP metrics to Prometheus write request" , "warnings" , ws )
458+ }
455459
456460 mimirTS := mimirpb .PreallocTimeseriesSliceFromPool ()
457461 for _ , ts := range promTS {
0 commit comments