apache / apache/lucene

Remove StringField [LUCENE-3792]

Open
#4,865 21 comments 0 reactions 0 assignees View on GitHub
affects-version:4.0-ALPHA legacy-jira-fix-version:4.9 legacy-jira-fix-version:6.0 legacy-jira-priority:Major type:task
Dominant language
Java
Stars
3.6k
Forks
1.4k
Avg merge
2d 11h
Merged PRs (30d)
88

Description

Often on the mailing list there is confusion about NOT_ANALYZED.

Besides being useless (Just use KeywordAnalyzer instead), people trip up on this
not being consistent at query time (you really need to configure KeywordAnalyzer for the field
on your PerFieldAnalyzerWrapper so it will do the same thing at query time... oh wait
once you've done that, you dont need NOT_ANALYZED).

So I think StringField is a trap too for the same reasons, just under a
different name, lets remove it.

---
Migrated from [LUCENE-3792](https://issues.apache.org/jira/browse/LUCENE-3792) by Robert Muir (@rmuir), updated May 09 2016
Attachments: [LUCENE-3792_javadocs_3x.patch](https://apache.github.io/lucene-jira-archive/attachments/LUCENE-3792/LUCENE-3792_javadocs_3x.patch) (versions: 2)
Linked issues:
- #5435

Contributor guide

Open the contributing guide

Research direction

Start by locating StringField and the NOT_ANALYZED references in the Lucene source; the issue does not name a file or test. Review linked issue #5435 and the discussion to determine the intended removal scope, then verify that the obsolete API and its related documentation or tests are no longer present.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
search
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.