Skip to content

Commit 1744785

Browse files
committed
Fix for ensuring that IVF format is supported for tests
1 parent 60bc9cf commit 1744785

File tree

3 files changed

+11
-11
lines changed

3 files changed

+11
-11
lines changed

muted-tests.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -559,12 +559,21 @@ tests:
559559
- class: org.elasticsearch.test.apmintegration.TracesApmIT
560560
method: testApmIntegration
561561
issue: https://github.com/elastic/elasticsearch/issues/129651
562+
- class: org.elasticsearch.search.query.RescoreKnnVectorQueryIT
563+
method: testKnnSearchRescore
564+
issue: https://github.com/elastic/elasticsearch/issues/129713
562565
- class: org.elasticsearch.snapshots.SnapshotShutdownIT
563566
method: testSnapshotShutdownProgressTracker
564567
issue: https://github.com/elastic/elasticsearch/issues/129752
565568
- class: org.elasticsearch.xpack.security.SecurityRolesMultiProjectIT
566569
method: testUpdatingFileBasedRoleAffectsAllProjects
567570
issue: https://github.com/elastic/elasticsearch/issues/129775
571+
- class: org.elasticsearch.search.query.RescoreKnnVectorQueryIT
572+
method: testKnnQueryRescore
573+
issue: https://github.com/elastic/elasticsearch/issues/129809
574+
- class: org.elasticsearch.search.query.RescoreKnnVectorQueryIT
575+
method: testKnnRetriever
576+
issue: https://github.com/elastic/elasticsearch/issues/129818
568577
- class: org.elasticsearch.qa.verify_version_constants.VerifyVersionConstantsIT
569578
method: testLuceneVersionConstant
570579
issue: https://github.com/elastic/elasticsearch/issues/125638

server/src/internalClusterTest/java/org/elasticsearch/search/query/RescoreKnnVectorQueryIT.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ protected Map<String, Function<Map<String, Object>, Object>> pluginScripts() {
8585
public void setup() throws IOException {
8686
String type = randomFrom(
8787
Arrays.stream(VectorIndexType.values())
88-
.filter(t -> t.isQuantized() && t.isEnabled())
88+
.filter(VectorIndexType::isQuantized)
8989
.map(t -> t.name().toLowerCase(Locale.ROOT))
9090
.collect(Collectors.toCollection(ArrayList::new))
9191
);

server/src/main/java/org/elasticsearch/index/mapper/vectors/DenseVectorFieldMapper.java

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1655,16 +1655,11 @@ public boolean supportsElementType(ElementType elementType) {
16551655
public boolean supportsDimension(int dims) {
16561656
return true;
16571657
}
1658-
1659-
@Override
1660-
public boolean isEnabled() {
1661-
return IVF_FORMAT.isEnabled();
1662-
}
16631658
};
16641659

16651660
public static Optional<VectorIndexType> fromString(String type) {
16661661
return Stream.of(VectorIndexType.values())
1667-
.filter(VectorIndexType::isEnabled)
1662+
.filter(vectorIndexType -> vectorIndexType != VectorIndexType.BBQ_IVF || IVF_FORMAT.isEnabled())
16681663
.filter(vectorIndexType -> vectorIndexType.name.equals(type))
16691664
.findFirst();
16701665
}
@@ -1691,10 +1686,6 @@ public boolean isQuantized() {
16911686
return quantized;
16921687
}
16931688

1694-
public boolean isEnabled() {
1695-
return true;
1696-
}
1697-
16981689
public String getName() {
16991690
return name;
17001691
}

0 commit comments

Comments
 (0)