Interface Http2GoAwayFrame

  • All Superinterfaces:
    io.netty.buffer.ByteBufHolder, Http2Frame, io.netty.util.ReferenceCounted
    All Known Implementing Classes:
    DefaultHttp2GoAwayFrame

    public interface Http2GoAwayFrame
    extends Http2Frame, io.netty.buffer.ByteBufHolder
    HTTP/2 GOAWAY frame.

    The last stream identifier must not be set by the application, but instead the relative extraStreamIds() should be used. The lastStreamId() will only be set for incoming GOAWAY frames by the HTTP/2 codec.

    Graceful shutdown as described in the HTTP/2 spec can be accomplished by calling #setExtraStreamIds(Integer.MAX_VALUE).

    • Method Detail

      • errorCode

        long errorCode()
        The reason for beginning closure of the connection. Represented as an HTTP/2 error code.
      • extraStreamIds

        int extraStreamIds()
        The number of IDs to reserve for the receiver to use while GOAWAY is in transit. This allows for new streams currently en route to still be created, up to a point, which allows for very graceful shutdown of both sides.
      • setExtraStreamIds

        Http2GoAwayFrame setExtraStreamIds​(int extraStreamIds)
        Sets the number of IDs to reserve for the receiver to use while GOAWAY is in transit.
        Returns:
        this
        See Also:
        extraStreamIds()
      • lastStreamId

        int lastStreamId()
        Returns the last stream identifier if set, or -1 else.
      • content

        io.netty.buffer.ByteBuf content()
        Optional debugging information describing cause the GOAWAY. Will not be null, but may be empty.
        Specified by:
        content in interface io.netty.buffer.ByteBufHolder
      • copy

        Http2GoAwayFrame copy()
        Specified by:
        copy in interface io.netty.buffer.ByteBufHolder
      • duplicate

        Http2GoAwayFrame duplicate()
        Specified by:
        duplicate in interface io.netty.buffer.ByteBufHolder
      • retainedDuplicate

        Http2GoAwayFrame retainedDuplicate()
        Specified by:
        retainedDuplicate in interface io.netty.buffer.ByteBufHolder
      • replace

        Http2GoAwayFrame replace​(io.netty.buffer.ByteBuf content)
        Specified by:
        replace in interface io.netty.buffer.ByteBufHolder
      • retain

        Http2GoAwayFrame retain()
        Specified by:
        retain in interface io.netty.buffer.ByteBufHolder
        Specified by:
        retain in interface io.netty.util.ReferenceCounted
      • retain

        Http2GoAwayFrame retain​(int increment)
        Specified by:
        retain in interface io.netty.buffer.ByteBufHolder
        Specified by:
        retain in interface io.netty.util.ReferenceCounted
      • touch

        Http2GoAwayFrame touch()
        Specified by:
        touch in interface io.netty.buffer.ByteBufHolder
        Specified by:
        touch in interface io.netty.util.ReferenceCounted
      • touch

        Http2GoAwayFrame touch​(Object hint)
        Specified by:
        touch in interface io.netty.buffer.ByteBufHolder
        Specified by:
        touch in interface io.netty.util.ReferenceCounted