1

In my application, I create a new metric with those dimensions

Collection<Dimension> dimensions =
    Arrays.asList(
      new Dimension().withName("PlacementString").withValue(form.getPlacementString()),
      new Dimension().withName("PlacementPage").withValue(String.valueOf(form.getPlacementPage())),
      new Dimension().withName("Domain").withValue(form.getDomain()));

and the Metric is

Collection<MetricDatum> metricData =
  Collections.singletonList(
    new MetricDatum()
      .withDimensions(dimensions)
      .withMetricName("XYZ")
      .withValue(1D)
      .withUnit("Count"));

In the above example, PlacementString could be something like foo or bar and the PlacementPage could be 1000 or any integer.

So, with every different combination of dimensions, a new metric will be created and published to cloudwatch what I intend to do is to have a widget in the dashboard on cloudwatch that logs metrics that are published from the app in a dynamic way, I checked the docs, and all that I saw was that we have to pre-define the metrics and the thing is that I don't know what I'm expecting

so, is there a way to have a wildcard so that if a new metric is published from the app to add it automatically in the widget?

Bilal Fakih
  • 101
  • 6

0 Answers0