@@ -221,7 +221,11 @@ private void handleFrame(ByteBuf frame) {
221221 break ;
222222 case REQUEST_CHANNEL :
223223 long channelInitialRequestN = RequestChannelFrameCodec .initialRequestN (frame );
224- handleChannel (streamId , frame , channelInitialRequestN );
224+ handleChannel (streamId , frame , channelInitialRequestN , false );
225+ break ;
226+ case REQUEST_CHANNEL_COMPLETE :
227+ long completeChannelInitialRequestN = RequestChannelFrameCodec .initialRequestN (frame );
228+ handleChannel (streamId , frame , completeChannelInitialRequestN , true );
225229 break ;
226230 case METADATA_PUSH :
227231 handleMetadataPush (metadataPush (super .getPayloadDecoder ().apply (frame )));
@@ -345,7 +349,7 @@ private void handleStream(int streamId, ByteBuf frame, long initialRequestN) {
345349 }
346350 }
347351
348- private void handleChannel (int streamId , ByteBuf frame , long initialRequestN ) {
352+ private void handleChannel (int streamId , ByteBuf frame , long initialRequestN , boolean complete ) {
349353 if (FrameHeaderCodec .hasFollows (frame )) {
350354 RequestChannelResponderSubscriber subscriber =
351355 new RequestChannelResponderSubscriber (streamId , initialRequestN , frame , this , this );
@@ -358,6 +362,9 @@ private void handleChannel(int streamId, ByteBuf frame, long initialRequestN) {
358362
359363 if (this .add (streamId , subscriber )) {
360364 this .requestChannel (firstPayload , subscriber ).subscribe (subscriber );
365+ if (complete ) {
366+ subscriber .handleComplete ();
367+ }
361368 }
362369 }
363370 }
0 commit comments