Uploaded image for project: 'Flink'
  1. Flink
  2. FLINK-9468

Wrong calculation of outputLimit in LimitedConnectionsFileSystem

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Fixed
    • 1.5.0
    • 1.5.1, 1.6.0
    • FileSystems
    • None

    Description

      In LimitedConnectionsFileSystem#createStream, we get the outputLimit incorrectly.

      private <T extends StreamWithTimeout> T createStream(
      	final SupplierWithException<T, IOException> streamOpener,
      	final HashSet<T> openStreams,
      	final boolean output) throws IOException {
      
      final int outputLimit = output && maxNumOpenInputStreams > 0 ? maxNumOpenOutputStreams : Integer.MAX_VALUE;
      /*....*/
      }
      

      should be

      private <T extends StreamWithTimeout> T createStream(
      	final SupplierWithException<T, IOException> streamOpener,
      	final HashSet<T> openStreams,
      	final boolean output) throws IOException {
      
      final int outputLimit = output && maxNumOpenOutputStreams > 0 ? maxNumOpenOutputStreams : Integer.MAX_VALUE;
      /*....*/
      }
      

      Attachments

        Issue Links

          Activity

            People

              sihuazhou Sihua Zhou
              sihuazhou Sihua Zhou
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: