Skip to content

Commit 7e0efd0

Browse files
authored
Merge branch 'main' into histo-tests-refactor
2 parents 6bf4488 + 7152e61 commit 7e0efd0

File tree

29 files changed

+434
-78
lines changed

29 files changed

+434
-78
lines changed

docs/reference/query-languages/esql/_snippets/functions/description/knn.md

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/reference/query-languages/esql/_snippets/functions/parameters/knn.md

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/reference/query-languages/esql/images/functions/knn.svg

Lines changed: 1 addition & 1 deletion
Loading

docs/reference/query-languages/esql/kibana/definition/functions/knn.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/reference/query-languages/esql/kibana/docs/functions/knn.md

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

muted-tests.yml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -456,12 +456,6 @@ tests:
456456
- class: org.elasticsearch.xpack.search.AsyncSearchErrorTraceIT
457457
method: testAsyncSearchFailingQueryErrorTraceDefault
458458
issue: https://github.com/elastic/elasticsearch/issues/133010
459-
- class: org.elasticsearch.upgrades.SyntheticSourceRollingUpgradeIT
460-
method: testIndexing {upgradedNodes=1}
461-
issue: https://github.com/elastic/elasticsearch/issues/133060
462-
- class: org.elasticsearch.upgrades.SyntheticSourceRollingUpgradeIT
463-
method: testIndexing {upgradedNodes=0}
464-
issue: https://github.com/elastic/elasticsearch/issues/133061
465459
- class: org.elasticsearch.xpack.ml.integration.TextEmbeddingQueryIT
466460
method: testModelWithPrefixStrings
467461
issue: https://github.com/elastic/elasticsearch/issues/133138

x-pack/plugin/esql-core/src/main/java/org/elasticsearch/xpack/esql/core/expression/Expression.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,10 @@ public TypeResolution and(TypeResolution other) {
5555
return failed ? this : other;
5656
}
5757

58+
public TypeResolution or(TypeResolution other) {
59+
return failed ? other : this;
60+
}
61+
5862
public TypeResolution and(Supplier<TypeResolution> other) {
5963
return failed ? this : other.get();
6064
}

x-pack/plugin/esql-core/src/main/java/org/elasticsearch/xpack/esql/core/type/DataType.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -395,6 +395,9 @@ public enum DataType {
395395
// ES calls this 'point', but ESQL calls it 'cartesian_point'
396396
map.put("point", DataType.CARTESIAN_POINT);
397397
map.put("shape", DataType.CARTESIAN_SHAPE);
398+
// semantic_text is returned as text by field_caps, but unit tests will retrieve it from the mapping
399+
// so we need to map it here as well
400+
map.put("semantic_text", DataType.TEXT);
398401
ES_TO_TYPE = Collections.unmodifiableMap(map);
399402
// DATETIME has different esType and typeName, add an entry in NAME_TO_TYPE with date as key
400403
map = TYPES.stream().collect(toMap(DataType::typeName, t -> t));
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
/*
2+
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
3+
* or more contributor license agreements. Licensed under the Elastic License
4+
* 2.0; you may not use this file except in compliance with the Elastic License
5+
* 2.0.
6+
*/
7+
8+
package org.elasticsearch.xpack.esql.qa.multi_node;
9+
10+
import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;
11+
12+
import org.elasticsearch.test.TestClustersThreadFilter;
13+
import org.elasticsearch.test.cluster.ElasticsearchCluster;
14+
import org.elasticsearch.xpack.esql.qa.rest.KnnSemanticTextTestCase;
15+
import org.junit.ClassRule;
16+
17+
@ThreadLeakFilters(filters = TestClustersThreadFilter.class)
18+
public class KnnSemanticTextIT extends KnnSemanticTextTestCase {
19+
@ClassRule
20+
public static ElasticsearchCluster cluster = Clusters.testCluster(
21+
spec -> spec.module("x-pack-inference").plugin("inference-service-test")
22+
);
23+
24+
@Override
25+
protected String getTestRestCluster() {
26+
return cluster.getHttpAddresses();
27+
}
28+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
/*
2+
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
3+
* or more contributor license agreements. Licensed under the Elastic License
4+
* 2.0; you may not use this file except in compliance with the Elastic License
5+
* 2.0.
6+
*/
7+
8+
package org.elasticsearch.xpack.esql.qa.single_node;
9+
10+
import com.carrotsearch.randomizedtesting.annotations.ThreadLeakFilters;
11+
12+
import org.elasticsearch.test.TestClustersThreadFilter;
13+
import org.elasticsearch.test.cluster.ElasticsearchCluster;
14+
import org.elasticsearch.xpack.esql.qa.rest.KnnSemanticTextTestCase;
15+
import org.junit.ClassRule;
16+
17+
@ThreadLeakFilters(filters = TestClustersThreadFilter.class)
18+
public class KnnSemanticTextIT extends KnnSemanticTextTestCase {
19+
20+
@ClassRule
21+
public static ElasticsearchCluster cluster = Clusters.testCluster(spec -> spec.plugin("inference-service-test"));
22+
23+
@Override
24+
protected String getTestRestCluster() {
25+
return cluster.getHttpAddresses();
26+
}
27+
}

0 commit comments

Comments
 (0)