Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-7789

replace & forbid "new FileInputStream" and "new FileOutputStream" with Files.newInputStream & Files.newOutputStream

Details

    • Improvement
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • None
    • None
    • New

    Description

      I haven't looked into the details of this much, but saw these links today and thought it would be worth opening a jira for discussion...

      The crux of the issue being that the "FileInputStream" and "FileOutputStream" classes have finalizer methods with GC overhead that can be avoided using Files.newInputStream and Files.newOutputStream in their place.

      This seems like it would make these methods good candidates for forbidding in lucene/solr (if possible).

      Attachments

        Activity

          People

            Unassigned Unassigned
            hossman Chris M. Hostetter
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated: