Ask Your Question
0

How can we convert a wavefront query into a Prometheus query?

asked 2023-07-17 19:14:47 +0000

plato gravatar image

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
3

answered 2023-07-17 19:24:02 +0000

djk gravatar image

To convert a wavefront query into a Prometheus query, follow these steps:

  1. Understand the metric syntax: The metric syntax for both Wavefront and Prometheus is different. Wavefront uses a dotted notation, whereas Prometheus uses a forward slash notation. For example, aws.ec2.cpu.utilization in Wavefront would be aws_ec2_cpu_utilization in Prometheus.

  2. Identify the aggregation functions: Wavefront supports a variety of aggregation functions, such as mean, max, min, sum, etc. Prometheus also has similar aggregation functions, such as avg, max_over_time, min_over_time, sum_over_time, etc.

  3. Convert time windows: Wavefront supports different time windows, such as 1h, 1d, 1w, etc. In Prometheus, you can convert time windows using the time() function, such as 1h would be time() - 1h.

  4. Add labels: Prometheus requires labels to identify the different dimensions of the data. You can add labels to a Prometheus query using the label_replace() function.

Overall, the process of converting a wavefront query into a Prometheus query depends on the specific metric and data you are working with.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss

Add Answer


Question Tools

Stats

Asked: 2023-07-17 19:14:47 +0000

Seen: 11 times

Last updated: Jul 17 '23