thanos icon indicating copy to clipboard operation
thanos copied to clipboard

FT add feature flag for 'promql-experimental-functions'.

Open AL82082 opened this issue 1 year ago • 3 comments

Is your proposal related to a problem?

I can't use sort_by_label promql experimental function in thanos-query to sort results by a label, e.g. "environment", where the values are like "dev", "qa", "uat".

This is needed to display results in Grafana Stat panel in a logical ordering.

Describe the solution you'd like

I would like to be able to provide a feature flag argument to the thanos docker image which enables promql experimental functions (sort_by_label, sort_by_label_desc, ...).

Describe alternatives you've considered

I can't add my prometheus instance as a separate Grafana Datasource, or an endpoint in thanos-query, because all of my long-term metrics are coming from S3 via thanos-store.

Additional context

Please see Issue #4022 or PR #4786 for an example of adding feature flag support.

AL82082 avatar Aug 14 '24 16:08 AL82082

How does this work with the new engine? @MichaHoffmann @fpetkovski Does the new engine support those experimental functions

yeya24 avatar Aug 14 '24 17:08 yeya24

How does this work with the new engine? @MichaHoffmann @fpetkovski Does the new engine support those experimental functions

Not yet but at least those sorting functions should be very easy to add!

Edit: something like this: https://github.com/thanos-io/promql-engine/pull/481 ?

MichaHoffmann avatar Aug 14 '24 17:08 MichaHoffmann

I appreciate the speedy response!

AL82082 avatar Aug 15 '24 12:08 AL82082

We still need to add a feature flag for promql-experimental-functions. Help wanted.

yeya24 avatar Nov 10 '24 19:11 yeya24

Hi @yeya24 , I have never worked on adding a feature flag before and would like to pick this up.

heysujal avatar Jan 09 '25 20:01 heysujal

We we close this now 👀 !?

Saumya40-codes avatar Jun 29 '25 14:06 Saumya40-codes