Skip to content

Commit

Permalink
PromQL: Promote negative offset and @ modifer to stable
Browse files Browse the repository at this point in the history
Following the argument that breaking the invariant that PromQL does
not look ahead of the evaluation time implies a breaking change, we
still need to keep the feature flag around, but at least we can
communicate that the feature is considered stable, and that the
feature flags will be ignored from v3 on.

Signed-off-by: beorn7 <beorn@grafana.com>
  • Loading branch information
beorn7 committed Jan 5, 2022
1 parent d26fd5c commit 8cb2f29
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmd/prometheus/main.go
Expand Up @@ -168,10 +168,10 @@ func (c *flagConfig) setFeatureListOptions(logger log.Logger) error {
switch o {
case "promql-at-modifier":
c.enablePromQLAtModifier = true
level.Info(logger).Log("msg", "Experimental promql-at-modifier enabled")
level.Info(logger).Log("msg", "promql-at-modifier enabled")
case "promql-negative-offset":
c.enablePromQLNegativeOffset = true
level.Info(logger).Log("msg", "Experimental promql-negative-offset enabled")
level.Info(logger).Log("msg", "promql-negative-offset enabled")
case "remote-write-receiver":
c.web.RemoteWriteReceiver = true
level.Info(logger).Log("msg", "Experimental remote-write-receiver enabled")
Expand Down
10 changes: 10 additions & 0 deletions docs/feature_flags.md
Expand Up @@ -18,6 +18,11 @@ They may be enabled by default in future versions.
The `@` modifier lets you specify the evaluation time for instant vector selectors,
range vector selectors, and subqueries. More details can be found [here](querying/basics.md#modifier).

This feature is considered stable, but since it breaks the invariant that
PromQL does not look ahead of the evaluation time, it still needs to be enabled
via this feature flag. The feature will be permanently enabled (and the feature
flag ignored) upon major release v3.

## Expand environment variables in external labels

`--enable-feature=expand-external-labels`
Expand All @@ -40,6 +45,11 @@ with more recent data.

More details can be found [here](querying/basics.md#offset-modifier).

This feature is considered stable, but since it breaks the invariant that
PromQL does not look ahead of the evaluation time, it still needs to be enabled
via this feature flag. The feature will be permanently enabled (and the feature
flag ignored) upon major release v3.

## Remote Write Receiver

`--enable-feature=remote-write-receiver`
Expand Down

0 comments on commit 8cb2f29

Please sign in to comment.