apache / apache/lucene

Avoid private nonnested classes [LUCENE-3525]

Open
#4,599 8 comments 0 reactions 0 assignees View on GitHub
affects-version:3.0.3 legacy-jira-priority:Minor module:core/store type:bug
Dominant language
Java
Stars
3.6k
Forks
1.4k
Avg merge
2d 11h
Merged PRs (30d)
88

Description

https://svn.apache.org/repos/asf/lucene/dev/trunk/lucene/src/java/org/apache/lucene/store/NativeFSLockFactory.java shows a private top-level class `NativeFSLock`. This is a JDK 1.0-ism which should be considered deprecated. Either use a nested class, or create a separate source file.

Can produce problems for tools. Cause of: https://netbeans.org/bugzilla/show_bug.cgi?id=204039

---
Migrated from [LUCENE-3525](https://issues.apache.org/jira/browse/LUCENE-3525) by Jesse Glick, updated Mar 25 2012
Attachments: [LUCENE-3525.diff](https://apache.github.io/lucene-jira-archive/attachments/LUCENE-3525/LUCENE-3525.diff)

Contributor guide

Open the contributing guide

Research direction

Start with lucene/src/java/org/apache/lucene/store/NativeFSLockFactory.java and inspect the private top-level NativeFSLock class. Review the attached LUCENE-3525.diff and decide whether the class should be nested or moved to a separate source file; done means the private top-level class is no longer present and the NetBeans tooling problem is addressed.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
backend, tooling
Issue type
Refactor
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.