Skip to content

Commit 96175ef

Browse files
committed
Backport required removing unsupported commands (only in 9.1)
1 parent 75babba commit 96175ef

File tree

7 files changed

+3
-63
lines changed

7 files changed

+3
-63
lines changed

docs/reference/esql/functions/functionNamedParams/qstr.asciidoc

Lines changed: 0 additions & 29 deletions
This file was deleted.

docs/reference/query-languages/esql/kibana/definition/commands/change_point.json

Lines changed: 0 additions & 6 deletions
This file was deleted.

docs/reference/query-languages/esql/kibana/definition/commands/fork.json

Lines changed: 0 additions & 5 deletions
This file was deleted.

docs/reference/query-languages/esql/kibana/definition/commands/rerank.json

Lines changed: 0 additions & 5 deletions
This file was deleted.

docs/reference/query-languages/esql/kibana/definition/commands/rrf.json

Lines changed: 0 additions & 6 deletions
This file was deleted.

docs/reference/query-languages/esql/kibana/definition/commands/sample.json

Lines changed: 0 additions & 5 deletions
This file was deleted.

x-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/plan/logical/CommandLicenseTests.java

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,7 @@ public void testLicenseCheck() {
4141
for (var commandName : getCommandClasses().keySet()) {
4242
Class<? extends LogicalPlan> commandClass = getCommandClasses().get(commandName);
4343
try {
44-
var arg = (commandClass == InlineStats.class) ? new Aggregate(Source.EMPTY, sourceCommand, null, null) : sourceCommand;
45-
checkLicense(commandName, createInstance(commandClass, arg));
44+
checkLicense(commandName, createInstance(commandClass, sourceCommand));
4645
} catch (Exception e) {
4746
Throwable c = e.getCause();
4847
fail("Failed to create instance of command class: " + commandClass.getName() + " - " + e.getMessage() + " - " + c);
@@ -155,11 +154,8 @@ private static LogicalPlan createInstance(Class<? extends LogicalPlan> clazz, Lo
155154
case "Grok" -> {
156155
return new Grok(source, child, null, null, List.of());
157156
}
158-
case "Fork" -> {
159-
return new Fork(source, List.of(child, child));
160-
}
161-
case "Sample" -> {
162-
return new Sample(source, null, null, child);
157+
case "InlineStats" -> {
158+
return new InlineStats(source, new Aggregate(Source.EMPTY, child, Aggregate.AggregateType.STANDARD, null, null));
163159
}
164160
case "LookupJoin" -> {
165161
return new LookupJoin(source, child, child, List.of());

0 commit comments

Comments
 (0)