Hacktoberfest 2026: as issues que os mantenedores marcaram para outubro, abertas e boas para iniciantes. Ver issues do Hacktoberfest

[Bug] Deleted rows take vector search top-k slots in data-evolution tables

Aberta
#454 0 comentários 0 reações 0 responsáveis Ver no GitHub

Mantenedores costumam responder em até 3 dias

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
4/5
Tempo estimado
3-5 dias
Facilidade para iniciantes
57/100
Tipo de issue
Bug
Clareza
Claramente especificada
Status de atividade
Ativa
Stack de tecnologia
cpp
Domínio
databases

Direção de pesquisa

Start with LiveRowGlobalIndexReader::VisitVectorSearch and compare its vector path with the full-text path that loads live rows before searching shards. The issue suggests combining VectorSearch.pre_filter with shard live rows through ReplacePreFilter, using GlobalIndexLiveRowFilter::LiveRows, or loading live rows before fan-out. Add coverage for the reproduction with three deleted nearest rows and verify that a limit of 3 returns 3 live rows when enough matches pass the filters.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

bug
Search before asking
  • I searched in the issues and found nothing similar.
Paimon-cpp version

main at commit 50ef548ec87cc444a153fb2a03789f9be768d610, with #448 applied.

Minimal reproduce step
  1. Create a data-evolution table with row tracking and deletion-vectors.enabled = true. Write 10 rows with a vector column, then build a vector global index on that column.
  2. Delete the three rows nearest to a query vector, using deletion vectors.
  3. Search for that vector with limit = 3 through GlobalIndexScan::CreateReader → VisitVectorSearch.
  4. Pass the result to ScanContextBuilder::SetGlobalIndexResult, then scan and read.
What doesn't meet your expectations?

The index still ranks the deleted rows, so they take all three top-k slots. The read then drops them, because deletion vectors are applied only at read time. The query returns 0 rows instead of 3.

#448 (for #403) excludes deleted rows only from full-text ranking: LiveRowGlobalIndexReader::VisitVectorSearch delegates unchanged, and live rows are loaded only before a full-text search fans out to the shards. Java filters vector search with the same live rows (apache/paimon#8459).

Expected: limit = k returns k live rows whenever at least k live rows pass the search's pre_filter and predicate.

Anything else?

Follow-up of #403 / #448.

Suggestions:

  • VectorSearch already carries a pre_filter over global row ids, so LiveRowGlobalIndexReader::VisitVectorSearch can combine it with the live rows of the shard through ReplacePreFilter, reusing GlobalIndexLiveRowFilter::LiveRows, and pass the search on unchanged when the whole shard is live.
  • Load live rows on the visiting thread before a vector search fans out to the shards, as LiveRowUnionGlobalIndexReader does for full-text search.
Are you willing to submit a PR?
  • I'm willing to submit a PR!
Linguagem predominante
C++
Estrelas
70
Forks
36
Merge médio
3d 16h
PRs com merge (30d)
38

Preparar o ambiente

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de apache/paimon-cpp

Todas as issues de apache/paimon-cpp

Issues semelhantes

Mais issues de C++

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.