Skip to content
This repository has been archived by the owner on Mar 25, 2020. It is now read-only.

Custom metrics with no dimensions do not save/display properly #135

Open
mcheshier1 opened this issue Sep 25, 2018 · 4 comments
Open

Custom metrics with no dimensions do not save/display properly #135

mcheshier1 opened this issue Sep 25, 2018 · 4 comments

Comments

@mcheshier1
Copy link

I'm on the latest version. (.64)

To reproduce:

  1. Create a custom metric with no dimensions.
  2. Select the custom metric from the drop-down list. It should look like metric - [].
  3. Click edit.
  4. Return to the selection screen. The DDL that should be populated is not.
  5. Add a dimension to the metric.
  6. Repeat the process. Metric saves as expected.
@ks888
Copy link
Owner

ks888 commented Sep 28, 2018

Thank you for your report, but I can't reproduce the issue.

Maybe I misunderstand some steps. Here are the steps I tried:

  1. Open the metrics page (https://xxxx.cloudfront.net/metrics).
  2. Click '+ Add' button.
  3. Enter the Title (like 'Metric 1').
  4. Click 'Add' button. Now the new metric is created.
  5. Click 'Pencil' icon to edit the metric.
  6. Choose namespace and dimensions.
  7. Click 'Edit' button. Now the metric is updated.
  8. Click 'Pencil' icon again.

After these steps, it looks like the new namespace and dimensions are saved correctly.

@mcheshier1
Copy link
Author

Hi ks888, did you point it at a metric with no dimensions? It should look like - []. Also the metric should show up under 'Metrics with no dimensions' in a custom namespace in Cloudwatch.

@jkrenge
Copy link

jkrenge commented Feb 7, 2019

@mcheshier1 Running into the same issue here, did you find a workaround? Does it make sense to add a dimension?

@jkrenge
Copy link

jkrenge commented Feb 7, 2019

If anyone stumbles upon this: An easy fix is to reuse your existing namespace and metric name for the dimension, then you'll be able to add them to LambStatus. In Node I'm using sth like this:

  var params = {
    MetricData: [
      {
        MetricName: metric,
        Timestamp: new Date(),
        Unit: 'Count',
        Value: value,
        Dimensions: [{
          Name: 'MyMetric',
          Value: metric,
        }],
      },
    ],
    Namespace: 'MyMetric/' + namespace,
  };

  CloudWatch.putMetricData(params, callback);

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants