Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Increment version to 2.12.0-SNAPSHOT and change imports to align with core lucene upgrade #1296

Merged
merged 3 commits into from
Nov 7, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ jobs:
strategy:
matrix:
java: [ 11, 17 ]
bwc_version : [ "1.1.0", "1.2.4", "1.3.8", "2.0.1", "2.1.0", "2.2.1", "2.3.0", "2.4.1", "2.5.0", "2.6.0", "2.7.0", "2.8.0", "2.9.0", "2.10.0" ]
opensearch_version : [ "2.11.0-SNAPSHOT" ]
bwc_version : [ "1.1.0", "1.2.4", "1.3.8", "2.0.1", "2.1.0", "2.2.1", "2.3.0", "2.4.1", "2.5.0", "2.6.0", "2.7.0", "2.8.0", "2.9.0", "2.10.0", "2.11.0" ]
opensearch_version : [ "2.12.0-SNAPSHOT" ]

name: k-NN Restart-Upgrade BWC Tests
runs-on: ubuntu-latest
Expand Down Expand Up @@ -46,8 +46,8 @@ jobs:
strategy:
matrix:
java: [ 11, 17 ]
bwc_version: [ "1.3.8", "2.0.1", "2.1.0", "2.2.1", "2.3.0", "2.4.1", "2.5.0", "2.6.0", "2.7.0", "2.8.0", "2.9.0", "2.10.0"]
opensearch_version: [ "2.11.0-SNAPSHOT" ]
bwc_version: [ "1.3.8", "2.0.1", "2.1.0", "2.2.1", "2.3.0", "2.4.1", "2.5.0", "2.6.0", "2.7.0", "2.8.0", "2.9.0", "2.10.0", "2.11.0"]
opensearch_version: [ "2.12.0-SNAPSHOT" ]

name: k-NN Rolling-Upgrade BWC Tests
runs-on: ubuntu-latest
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ buildscript {
ext {
// build.version_qualifier parameter applies to knn plugin artifacts only. OpenSearch version must be set
// explicitly as 'opensearch.version' property, for instance opensearch.version=2.0.0-rc1-SNAPSHOT
opensearch_version = System.getProperty("opensearch.version", "2.11.0-SNAPSHOT")
opensearch_version = System.getProperty("opensearch.version", "2.12.0-SNAPSHOT")
version_qualifier = System.getProperty("build.version_qualifier", "")
opensearch_group = "org.opensearch"
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
import java.util.Locale;
import java.util.Optional;

import static org.apache.lucene.index.VectorValues.MAX_DIMENSIONS;
import org.apache.lucene.codecs.KnnVectorsFormat;
import static org.opensearch.knn.common.KNNConstants.VECTOR_DATA_TYPE_FIELD;
import static org.opensearch.knn.index.mapper.KNNVectorFieldMapperUtil.addStoredFieldForVectorField;
import static org.opensearch.knn.index.mapper.KNNVectorFieldMapperUtil.buildDocValuesFieldType;
Expand All @@ -33,7 +33,7 @@
*/
public class LuceneFieldMapper extends KNNVectorFieldMapper {

private static final int LUCENE_MAX_DIMENSION = MAX_DIMENSIONS;
private static final int LUCENE_MAX_DIMENSION = KnnVectorsFormat.DEFAULT_MAX_DIMENSIONS;

/** FieldType used for initializing VectorField, which is used for creating binary doc values. **/
private final FieldType vectorFieldType;
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/org/opensearch/knn/index/util/KNNEngine.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
package org.opensearch.knn.index.util;

import com.google.common.collect.ImmutableSet;
import org.apache.lucene.index.VectorValues;
import org.apache.lucene.codecs.KnnVectorsFormat;
import org.opensearch.common.ValidationException;
import org.opensearch.knn.index.KNNMethod;
import org.opensearch.knn.index.KNNMethodContext;
Expand Down Expand Up @@ -40,7 +40,7 @@ public enum KNNEngine implements KNNLibrary {
KNNEngine.FAISS,
16_000,
KNNEngine.LUCENE,
VectorValues.MAX_DIMENSIONS
KnnVectorsFormat.DEFAULT_MAX_DIMENSIONS
);

/**
Expand Down
Loading