ShrinkWrap
  1. ShrinkWrap
  2. SHRINKWRAP-469

ShrinkWrapDirectoryStream.iterator missing IllegalStateException cases

    Details

    • Type: Bug Bug
    • Status: Closed Closed (View Workflow)
    • Priority: Minor Minor
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: 1.2.1
    • Component/s: None
    • Labels:
      None
    • Similar Issues:
      Show 10 results 

      Description

      Unfortunately the nio2 API was designed before Java8's stream library.

      The documentation says that ShrinkWrapDirectoryStream.iterator must throw IllegalStateException if the Stream is closed OR if the iterator() has been accessed already.

      From my reading of the DirectoryStream javadoc, the implementation of Iterator is otherwise fine. close() does not have to prematurely terminate the Iterator. iterator() should just comply with the precondition exceptions.

      ShrinkWrapDirectoryStream is package protected, there is no reason to discuss any relationship to SecureDirectoryStream.

        Activity

        Hide
        Andrew Rubinger
        added a comment -

        Thanks for the report; was there an associated PR?

        Show
        Andrew Rubinger
        added a comment - Thanks for the report; was there an associated PR?
        Hide
        Under Flowerpot
        added a comment -

        No PR. I investigate shrinkwrap for its standalone features and implementation. I am experimenting with my own nio2 FileSystem implementation of Zookeeper.

        Show
        Under Flowerpot
        added a comment - No PR. I investigate shrinkwrap for its standalone features and implementation. I am experimenting with my own nio2 FileSystem implementation of Zookeeper.
        Hide
        Andrew Rubinger
        added a comment -

        Upstream:

        ce6d593
        4752271

        Show
        Andrew Rubinger
        added a comment - Upstream: ce6d593 4752271

          People

          • Assignee:
            Michal Matloka
            Reporter:
            Under Flowerpot
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: