Class HTTP2Session.ControlEntry

java.lang.Object
org.eclipse.jetty.util.Callback.Completing
org.eclipse.jetty.util.Callback.Nested
org.eclipse.jetty.http2.HTTP2Flusher.Entry
org.eclipse.jetty.http2.HTTP2Session.ControlEntry
All Implemented Interfaces:
org.eclipse.jetty.util.Callback, org.eclipse.jetty.util.thread.Invocable
Enclosing class:
HTTP2Session

private class HTTP2Session.ControlEntry extends HTTP2Flusher.Entry
  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.eclipse.jetty.util.Callback

    org.eclipse.jetty.util.Callback.Completable, org.eclipse.jetty.util.Callback.Completing, org.eclipse.jetty.util.Callback.Nested

    Nested classes/interfaces inherited from interface org.eclipse.jetty.util.thread.Invocable

    org.eclipse.jetty.util.thread.Invocable.InvocationType
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private int
     

    Fields inherited from class org.eclipse.jetty.http2.HTTP2Flusher.Entry

    frame, stream

    Fields inherited from interface org.eclipse.jetty.util.Callback

    NOOP

    Fields inherited from interface org.eclipse.jetty.util.thread.Invocable

    __nonBlocking
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    private
    ControlEntry(Frame frame, IStream stream, org.eclipse.jetty.util.Callback callback)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    private void
    Performs actions just before writing the frame to the network.
    protected boolean
    generate(org.eclipse.jetty.io.ByteBufferPool.Lease lease)
     
    int
     
    (package private) boolean
     
    long
    onFlushed(long bytes)
     
    void
     

    Methods inherited from class org.eclipse.jetty.http2.HTTP2Flusher.Entry

    commit, failed, getDataBytesRemaining, toString

    Methods inherited from class org.eclipse.jetty.util.Callback.Nested

    getCallback, getInvocationType

    Methods inherited from class org.eclipse.jetty.util.Callback.Completing

    completed

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

    • frameBytes

      private int frameBytes
  • Constructor Details

    • ControlEntry

      private ControlEntry(Frame frame, IStream stream, org.eclipse.jetty.util.Callback callback)
  • Method Details

    • getFrameBytesGenerated

      public int getFrameBytesGenerated()
      Specified by:
      getFrameBytesGenerated in class HTTP2Flusher.Entry
    • generate

      protected boolean generate(org.eclipse.jetty.io.ByteBufferPool.Lease lease) throws HpackException
      Specified by:
      generate in class HTTP2Flusher.Entry
      Throws:
      HpackException
    • onFlushed

      public long onFlushed(long bytes)
      Specified by:
      onFlushed in class HTTP2Flusher.Entry
    • beforeSend

      private void beforeSend()

      Performs actions just before writing the frame to the network.

      Some frame, when sent over the network, causes the receiver to react and send back frames that may be processed by the original sender *before* succeeded() is called.

      If the action to perform updates some state, this update may not be seen by the received frames and cause errors.

      For example, suppose the action updates the stream window to a larger value; the sender sends the frame; the receiver is now entitled to send back larger data; when the data is received by the original sender, the action may have not been performed yet, causing the larger data to be rejected, when it should have been accepted.

    • hasHighPriority

      boolean hasHighPriority()
      Overrides:
      hasHighPriority in class HTTP2Flusher.Entry
    • succeeded

      public void succeeded()
      Specified by:
      succeeded in interface org.eclipse.jetty.util.Callback
      Overrides:
      succeeded in class org.eclipse.jetty.util.Callback.Nested