Skip to content

Commit ffa50fe

Browse files
committed
Increment promql capability version
1 parent afedd80 commit ffa50fe

File tree

9 files changed

+12
-12
lines changed

9 files changed

+12
-12
lines changed

x-pack/plugin/esql/qa/server/src/main/java/org/elasticsearch/xpack/esql/qa/rest/generative/GenerativeForkRestTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ protected void shouldSkipTest(String testName) throws IOException {
6262

6363
assumeFalse(
6464
"Tests using PROMQL are not supported for now",
65-
testCase.requiredCapabilities.contains(PROMQL_PRE_TECH_PREVIEW_V1.capabilityName())
65+
testCase.requiredCapabilities.contains(PROMQL_PRE_TECH_PREVIEW_V2.capabilityName())
6666
);
6767

6868
assumeFalse(

x-pack/plugin/esql/qa/testFixtures/src/main/resources/k8s-timeseries-avg-over-time.csv-spec

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ cost:double | time_bucket:datetime
1818
;
1919

2020
avg_over_time_of_double_no_grouping_promql
21-
required_capability: promql_pre_tech_preview_v1
21+
required_capability: promql_pre_tech_preview_v2
2222
TS k8s
2323
| PROMQL step 1m (sum(avg_over_time(network.cost[1m])))
2424
| SORT `sum(avg_over_time(network.cost[1m]))` DESC, step DESC | LIMIT 10;
@@ -47,7 +47,7 @@ cost:double | time_bucket:datetime
4747
;
4848

4949
avg_over_time_of_double_no_grouping_single_bucket_promql
50-
required_capability: promql_pre_tech_preview_v1
50+
required_capability: promql_pre_tech_preview_v2
5151
TS k8s
5252
| PROMQL step 1h (sum(avg_over_time(network.cost[1h])));
5353

x-pack/plugin/esql/qa/testFixtures/src/main/resources/k8s-timeseries-promql.csv-spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
promql_start_end_step
2-
required_capability: promql_pre_tech_preview_v1
2+
required_capability: promql_pre_tech_preview_v2
33
TS k8s
44
| PROMQL step 5m start "2024-05-10T00:20:00.000Z" end "2024-05-10T00:25:00.000Z" (
55
sum(avg_over_time(network.cost[5m]))

x-pack/plugin/esql/qa/testFixtures/src/main/resources/k8s-timeseries.csv-spec

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ max(rate(network.total_bytes_in)): double | time_bucket:date
133133
;
134134

135135
oneRateWithPromql
136-
required_capability: promql_pre_tech_preview_v1
136+
required_capability: promql_pre_tech_preview_v2
137137
TS k8s
138138
| PROMQL step 5m (max(rate(network.total_bytes_in[5m])))
139139
| SORT step DESC | LIMIT 2;
@@ -154,7 +154,7 @@ max(rate(network.total_bytes_in)): double | time_bucket:date
154154
;
155155

156156
oneRateWithSingleStepPromql
157-
required_capability: promql_pre_tech_preview_v1
157+
required_capability: promql_pre_tech_preview_v2
158158
TS k8s
159159
| PROMQL step 1h (max(rate(network.total_bytes_in[1h])));
160160

x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/action/EsqlCapabilities.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1705,7 +1705,7 @@ public enum Cap {
17051705
* As soon as we move into tech preview, we'll replace this capability with a "EXPONENTIAL_HISTOGRAM_TECH_PREVIEW" one.
17061706
* At this point, we need to add new capabilities for any further changes.
17071707
*/
1708-
PROMQL_PRE_TECH_PREVIEW_V1(Build.current().isSnapshot()),
1708+
PROMQL_PRE_TECH_PREVIEW_V2(Build.current().isSnapshot()),
17091709

17101710
/**
17111711
* KNN function adds support for k and visit_percentage options

x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/action/PromqlFeatures.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@ private PromqlFeatures() {
2121
* Exists to provide a single point of change and minimize noise when upgrading capability versions.
2222
*/
2323
public static boolean isEnabled() {
24-
return EsqlCapabilities.Cap.TS_COMMAND_V0.isEnabled() && EsqlCapabilities.Cap.PROMQL_PRE_TECH_PREVIEW_V1.isEnabled();
24+
return EsqlCapabilities.Cap.TS_COMMAND_V0.isEnabled() && EsqlCapabilities.Cap.PROMQL_PRE_TECH_PREVIEW_V2.isEnabled();
2525
}
2626
}

x-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/CsvTests.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,7 @@ public final void test() throws Throwable {
301301
);
302302
assumeFalse(
303303
"can't load metrics in csv tests",
304-
testCase.requiredCapabilities.contains(EsqlCapabilities.Cap.PROMQL_PRE_TECH_PREVIEW_V1.capabilityName())
304+
testCase.requiredCapabilities.contains(EsqlCapabilities.Cap.PROMQL_PRE_TECH_PREVIEW_V2.capabilityName())
305305
);
306306
assumeFalse(
307307
"can't use QSTR function in csv tests",
@@ -365,7 +365,7 @@ public final void test() throws Throwable {
365365
);
366366
assumeFalse(
367367
"can't use PromQL in csv tests",
368-
testCase.requiredCapabilities.contains(EsqlCapabilities.Cap.PROMQL_PRE_TECH_PREVIEW_V1.capabilityName())
368+
testCase.requiredCapabilities.contains(EsqlCapabilities.Cap.PROMQL_PRE_TECH_PREVIEW_V2.capabilityName())
369369
);
370370

371371
if (Build.current().isSnapshot()) {

x-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/telemetry/VerifierMetricsTests.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -816,7 +816,7 @@ public void testBinaryPlanAfterSubqueryInFromCommand() {
816816

817817
@AwaitsFix(bugUrl = "unresolved @timestamp field")
818818
public void testPromql() {
819-
assumeTrue("PromQL required", EsqlCapabilities.Cap.PROMQL_PRE_TECH_PREVIEW_V1.isEnabled());
819+
assumeTrue("PromQL required", EsqlCapabilities.Cap.PROMQL_PRE_TECH_PREVIEW_V2.isEnabled());
820820
Counters c = esql("""
821821
TS metrics
822822
| PROMQL step 5m (sum(salary))""");

x-pack/plugin/src/yamlRestTest/resources/rest-api-spec/test/esql/60_usage.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ setup:
5858
- ts_command_v0
5959
- cosine_vector_similarity_function
6060
- inline_stats
61-
- promql_pre_tech_preview_v1
61+
- promql_pre_tech_preview_v2
6262
reason: "Test that should only be executed on snapshot versions"
6363

6464
- do: { xpack.usage: { } }

0 commit comments

Comments
 (0)