Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8147894 Refresh jlink API
  3. JDK-8147794

Jlink's ModuleEntry.stream can't be consumed more than once and ModuleEntry content should be read only if needed

    XMLWordPrintable

Details

    • b125

    Description

      If the same stream is read in multiple plugins, then this could be difficult to investigate.
      For example:
      In plugin m1, the stream of a ModuleData instance is read then the ModuleData instance is added to the output pool (and not replaced by a new instance).
      If plugin m2 tries to read the stream, it will get a consumed stream.

      We could:
      - if markIsSupported, mark the stream at creation time, reset it each time it is returned.
      - if !markIsSupported, read the stream fully and expose a new ByteArrayInputStream when required.

      Attachments

        Issue Links

          Activity

            People

              sundar Sundararajan Athijegannathan
              jfdenise Jean-Francois Denise (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: