apache / apache/lucene

Can FST read bytes forward?

Open
#12,355 7 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
3.6k
Forks
1.4k
Avg merge
2d 11h
Merged PRs (30d)
88

Description

### Description

Forked from https://lists.apache.org/thread/1fskhmz84pp60o41txsxj2193vt9txod: the fact that FST reads bytes backwards doesn't play well with BufferedIndexInput, which triggers a refill on every byte read. Could we reverse these sequences of bytes at index time so that they would be read in forward order at search time?

Contributor guide

Open the contributing guide

Research direction

Start by tracing how FST reads byte sequences and how BufferedIndexInput refills during those reads; the issue identifies index time and search time as the relevant phases. Compare the current backward-read behavior with forward reads and determine whether the proposed ordering avoids a refill on every byte without breaking search results.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
search
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.