apache / apache/lucene

For SolrQueryParserBase.getPrefixQuery(String field, String termStr), use BytesRef from calling FieldType.readableToIndexed for Term [LUCENE-5082]

Open
#6,146 0 comments 0 reactions 0 assignees View on GitHub
affects-version:4.3 legacy-jira-label:parser legacy-jira-label:prefix 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

Currently, SolrQueryParserBase.getFieldQuery calls FieldType.getFieldQuery, which in turn calls readableToIndexed to get a type-specific BytesRef to pass to Term constructor. I would like SolrQueryParserBase.getPrefixQuery to do the same thing so that I can implement my own indexed binary field and allow my field to process my base64 encoded string query.

---
Migrated from [LUCENE-5082](https://issues.apache.org/jira/browse/LUCENE-5082) by Jessica Cheng Mallet

Contributor guide

Open the contributing guide

Research direction

Start with SolrQueryParserBase.getPrefixQuery and compare it with getFieldQuery and FieldType.getFieldQuery, focusing on readableToIndexed and Term construction. Then locate the relevant parser tests and verify that a custom indexed binary field can process a base64-encoded prefix query through its FieldType; done means the prefix path uses the type-specific BytesRef.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
search
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.