Is your feature request related to a problem? Please describe.
When capturing cold start metric using the Metrics utility, it adds an additional dimension named function_name.
Based on how EMF and CloudWatch Metric visualization work, this means we accidentally have two operational modes:
- Cold start behaviour: All custom metrics and ColdStart metric are plot with
function_name, service, <any custom dimension> dimensions
- Warm start behaviour: All custom metrics are plot with
service, <any custom dimension>
This causes any custom metric to have data points in two different metrics with the same name when visualizing it, because from a CloudWatch point of view they're unique (different dimensions).

Describe the solution you'd like
After discussing this extensively with @cakepietoast and @nmoutschen, we could plot ColdStart metric as a separate EMF blob to ensure backwards compatibility, and prevent new data points to be split.
Describe alternatives you've considered
- Adding
function_name as a default dimension across all metrics - This would cause an increased billing on CloudWatch
- Removing
function_name dimension, and log function details as metadata - This would break existing customers dashboard, and make KPI impact analysis more difficult
Additional context
Is your feature request related to a problem? Please describe.
When capturing cold start metric using the Metrics utility, it adds an additional dimension named
function_name.Based on how EMF and CloudWatch Metric visualization work, this means we accidentally have two operational modes:
function_name,service,<any custom dimension>dimensionsservice,<any custom dimension>This causes any custom metric to have data points in two different metrics with the same name when visualizing it, because from a CloudWatch point of view they're unique (different dimensions).
Describe the solution you'd like
After discussing this extensively with @cakepietoast and @nmoutschen, we could plot ColdStart metric as a separate EMF blob to ensure backwards compatibility, and prevent new data points to be split.
Describe alternatives you've considered
function_nameas a default dimension across all metrics - This would cause an increased billing on CloudWatchfunction_namedimension, and log function details as metadata - This would break existing customers dashboard, and make KPI impact analysis more difficultAdditional context