The Flow.Subscription should be used to control WINDOW_UPDATE (in HTTP/2) and selector registration (HTTP/1.1)

XMLWordPrintable

    • Type: Bug
    • Resolution: Unresolved
    • Priority: P4
    • tbd
    • Affects Version/s: 9
    • Component/s: core-libs
    • None

      In our current implementation, HTTP/2 Stream and HTTP/1.1 Response use a BlockingPushPublisher to publish received ByteBuffers to the Flow.Subscriber. When the demand made through Subscription.request reaches 0, the BlockingPushPublisher will block before calling onNext() if its acceptData(ByteBuffer) method is called.

      A better implementation might be to somehow relay the state of the subscriber's demand upstream (to the selector's loop for HTTP/1.1, and to the HTTP/2 server's through WINDOW_UPDATE frames) so that acceptData is never called if the demand reaches 0.

            Assignee:
            Michael McMahon
            Reporter:
            Daniel Fuchs
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: