Skip to content

Validate zero vectors in setVectorValue() for cosine similarity fields#16098

Open
iprithv wants to merge 1 commit into
apache:mainfrom
iprithv:fix-zero-vector-setvalue
Open

Validate zero vectors in setVectorValue() for cosine similarity fields#16098
iprithv wants to merge 1 commit into
apache:mainfrom
iprithv:fix-zero-vector-setvalue

Conversation

@iprithv
Copy link
Copy Markdown
Contributor

@iprithv iprithv commented May 21, 2026

PR #15751 added zero-vector validation in KnnByteVectorField and KnnFloatVectorField constructors when cosine similarity is configured. However, setVectorValue() was not covered, allowing users to bypass the check by creating a field with a valid vector and then mutating it to a zero vector. This can still lead to the same MergeAbortedException / CheckIndex failures described in #15540.

@iprithv iprithv force-pushed the fix-zero-vector-setvalue branch 2 times, most recently from 0b76047 to 7831c43 Compare May 21, 2026 21:32
@github-actions github-actions Bot added this to the 11.0.0 milestone May 21, 2026
@iprithv iprithv force-pushed the fix-zero-vector-setvalue branch from 7831c43 to 9861923 Compare May 21, 2026 22:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant