Migration notes for Tanzu (Wavefront) to PromQL

WavefrontQL and PromQL are both used to visualize data, and some functions are very similar. Use this information for guidance as you convert queries from Wavefront to Prometheus.

Functions

WavefrontPromQLNotes
abs()abs()none
exists()absent()WavefrontQL must use the ts() function.
unsupportedabsent_over_time()none
ceil()ceil()WavefrontQL must use the ts() function.
unsupportedchanges()none
limit()clamp_max()none
floor()clamp_min()none
day()day_of_month()Wavefront needs to specify the time zone with the day function. PromQL returns results in Coordinated Universal Time (UTC).
weekday()day_of_week()none
daysInMonth()days_in_month()none
align()<aggr>_over_time()none
deriv()deriv()none
exp()exp()none
unsupportedfloor()none
percentile()histogram_quantile()In PromQL, use histogram_quantile(0.95, sum by (le) rate(my_histogram_metric_bucket[1m])) to get the ninety-fifth percentile.
hw()holt_winters()none
hour()hour()none
unsupportedidelta()Use only with gauges in PromQL.
ratediff()increase() or irate()WavefrontQl ratediff() gives you the only difference in value between each two data points.
join()label_join()Wavefront can do specific joins like SQL.
taggify()label_replace()none
log()ln()none
unsupportedlog2()none
log10()log10()none
minute()minute()PromQL returns results in Coordinated Universal Time (UTC). You must specify a timezone in WavefrontQL.
month()month()PromQL returns results in Coordinated Universal Time (UTC). You must specify a timezone in WavefrontQL.
linearforecast()predict_linear()WavefrontQL can specify a length of time in the past for use with predicting the linear regression. PromQL predicts using the entire series, for use only with gauges.
rate()rate()none
flapping()resets()none
round()round()PromQL rounds up the tied values.
unsupportedscalar()none
unsupportedsort()PromQL sort() and sort_desc() show the data order in the Console view. Because Wavefront visualizes queries in charts instead of a console, they don't support this option.
unsupportedsort_desc()PromQL sort() and sort_desc() show the data order in the Console view. Because Wavefront visualizes queries in charts instead of a console, they don't support this option.
sqrt()sqrt()none
time()time()none
timestamp()timestamp()none
unsupportedvector()none
year()year()PromQL returns results in Coordinated Universal Time (UTC). You must specify a timezone in WavefrontQL.

Time functions

WavefrontPromQLNotes
mavg()avg_over_time()none
min()min_over_time()WavefrontQL must use the ts() function to match min_over_time().
max()max_over_time()WavefrontQL must use the following form to match max_over_time().
msum()sum_over_time()sum_over_time() is applicable only to gauges.
mcount()count_over_time()none
percentile()quantile_over_time()WavefrontQL requires the rawpercentile() function instead of percentile().
stddev_over_time()none
stdvar_over_time()none

Aggregations

WavefrontPromQLNotes
rawsum()sum()none
min()min()To emulate PromQl, use the following WavefrontQL form.
max()max()To emulate PromQl, use the following WavefrontQL form.
avg()avg()To emulate PromQL, use the following WavefrontQL form.
group()none
stddev()stddev()WavefrontQL can do only standard deviation on histograms.
variance()stdvar()The variance() function uses interpolation. To not use interpolation, use rawvariance().
count()count()WavefrontQL must use the ts() function to approximate the effect of the PromQL function.
count()count_values()To emulate PromQL function, use a Wavefront events function.
bottomk()bottomk()none
topk()topk()none
quantile()none

Binary operators

WavefrontPromQLNotes
.eq()==none
.ne()!=none
.gt()>none
.lt()<none
.ge()>=none
.le()<=none

Boolean operations

WavefrontPromQLNotes
intersect()andintersection
union()orunion
complement()unlesscomplement