[ 
https://issues.apache.org/jira/browse/LUCENE-3525?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13146356#comment-13146356
 ] 

Jesse Glick commented on LUCENE-3525:
-------------------------------------

BTW I missed {{TransactionLog}} (in {{FSUpdateLog.java}}) before.

"surely it's a transient bug" - probably existed for years. There is just not 
that much code out there using JDK 1.0 private classes for people to notice it 
earlier.

"will be fixed soon" - no idea. For the same reason, it is not a high priority. 
Anyway there are surely other things affected. While hyperlinking stack traces 
with such classes is easy enough once you know about it (for {{\tat 
p.B(A.java:123)}} ignore {{B}} and open {{p/A.java}}), other tool features can 
be harder to fix since you need a bytecode parser.

"why would {{NullUpdateLog}} be scoped within {{FSUpdateLong}}" - no good 
reason that I can see. Why was it in {{FSUpdateLong.java}}? A candidate for 
refactoring of some kind, in this case probably to be moved into 
{{UpdateHandler.java}}.

"{{Class.forName}} used by Solr configuration" - perhaps, though remember that 
these classes are necessarily package-private so not usable via reflection 
unless {{setAccessible(true)}} is called. For such cases (is there a list?) you 
would want to move the class into its own source file. For a committer this 
would be simple enough; for purposes of a submitted patch I did not want to 
make any such changes because the diff would be unreviewable and unlikely to 
apply cleanly after other trunk changes.
                
> Avoid private nonnested classes
> -------------------------------
>
>                 Key: LUCENE-3525
>                 URL: https://issues.apache.org/jira/browse/LUCENE-3525
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: core/store
>    Affects Versions: 3.0.3
>            Reporter: Jesse Glick
>            Priority: Minor
>         Attachments: LUCENE-3525.diff
>
>
> 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

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to