apache / apache/lucene

Performance improvements for FastCharStream [LUCENE-5723]

Open
#6,785 2 comments 0 reactions 0 assignees View on GitHub
legacy-jira-priority:Minor module:core/queryparser type:enhancement
Dominant language
Java
Stars
3.6k
Forks
1.4k
Avg merge
2d 11h
Merged PRs (30d)
88

Description

Hello from the .NET land,

A user of ours has identified an optimization opportunity, although minor I think it points to a valid point - we should avoid using exceptions from controlling flow when possible.

Here's the original ticket + commits to our codebase. If this looks valid to you too I can go ahead and prepare a PR.

https://issues.apache.org/jira/browse/LUCENENET-541
https://github.com/apache/lucene.net/commit/ac8c9fa809110ddb180bf7b2ce93e86270b39ff6
https://git-wip-us.apache.org/repos/asf?p=lucenenet.git;a=blobdiff;f=src/core/QueryParser/QueryParserTokenManager.cs;h=ec09c8e451f7a7d1572fbdce4c7598e362526a7c;hp=17583d20f660fdb6e4aa86105c7574383f965ebe;hb=41ebbc2d;hpb=ac8c9fa809110ddb180bf7b2ce93e86270b39ff6

---
Migrated from [LUCENE-5723](https://issues.apache.org/jira/browse/LUCENE-5723) by Itamar Syn-Hershko, updated Dec 09 2014

Contributor guide

Open the contributing guide

Research direction

Start with the linked Lucene commit and the diff for src/core/QueryParser/QueryParserTokenManager.cs, then compare the corresponding current implementation. Verify that the proposed FastCharStream optimization preserves parser behavior and identify existing tests that cover it; done means the behavior remains covered without using exceptions for normal control flow.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp, java
Domain
performance, search
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.