Package org.eclipse.jetty.http2
Class HTTP2Flusher
- java.lang.Object
-
- org.eclipse.jetty.util.IteratingCallback
-
- org.eclipse.jetty.http2.HTTP2Flusher
-
- All Implemented Interfaces:
org.eclipse.jetty.util.Callback,org.eclipse.jetty.util.component.Dumpable,org.eclipse.jetty.util.thread.Invocable
public class HTTP2Flusher extends org.eclipse.jetty.util.IteratingCallback implements org.eclipse.jetty.util.component.Dumpable
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classHTTP2Flusher.Entryprivate classHTTP2Flusher.WindowEntry-
Nested classes/interfaces inherited from class org.eclipse.jetty.util.IteratingCallback
org.eclipse.jetty.util.IteratingCallback.Action
-
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
-
-
Field Summary
Fields Modifier and Type Field Description private static java.nio.ByteBuffer[]EMPTY_BYTE_BUFFERSprivate java.util.Deque<HTTP2Flusher.Entry>entriesprivate org.eclipse.jetty.util.thread.Invocable.InvocationTypeinvocationTypeprivate org.eclipse.jetty.io.ByteBufferPool.Leaseleaseprivate static org.eclipse.jetty.util.log.LoggerLOGprivate java.util.Queue<HTTP2Flusher.Entry>pendingEntriesprivate java.util.Collection<HTTP2Flusher.Entry>processedEntriesprivate HTTP2Sessionsessionprivate HTTP2Flusher.EntrystalledEntryprivate java.lang.Throwableterminatedprivate java.util.Queue<HTTP2Flusher.WindowEntry>windows
-
Constructor Summary
Constructors Constructor Description HTTP2Flusher(HTTP2Session session)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanappend(java.util.List<HTTP2Flusher.Entry> list)booleanappend(HTTP2Flusher.Entry entry)private voidclosed(HTTP2Flusher.Entry entry, java.lang.Throwable failure)java.lang.Stringdump()voiddump(java.lang.Appendable out, java.lang.String indent)private voidfinish()intgetFrameQueueSize()org.eclipse.jetty.util.thread.Invocable.InvocationTypegetInvocationType()private intgetWindowQueueSize()protected voidonCompleteFailure(java.lang.Throwable x)protected voidonCompleteSuccess()(package private) voidonFlushed(long bytes)booleanprepend(HTTP2Flusher.Entry entry)protected org.eclipse.jetty.util.IteratingCallback.Actionprocess()voidsucceeded()(package private) voidterminate(java.lang.Throwable cause)java.lang.StringtoString()voidwindow(IStream stream, WindowUpdateFrame frame)-
Methods inherited from class org.eclipse.jetty.util.IteratingCallback
close, failed, isClosed, isFailed, isSucceeded, iterate, reset
-
-
-
-
Field Detail
-
LOG
private static final org.eclipse.jetty.util.log.Logger LOG
-
EMPTY_BYTE_BUFFERS
private static final java.nio.ByteBuffer[] EMPTY_BYTE_BUFFERS
-
windows
private final java.util.Queue<HTTP2Flusher.WindowEntry> windows
-
entries
private final java.util.Deque<HTTP2Flusher.Entry> entries
-
pendingEntries
private final java.util.Queue<HTTP2Flusher.Entry> pendingEntries
-
processedEntries
private final java.util.Collection<HTTP2Flusher.Entry> processedEntries
-
session
private final HTTP2Session session
-
lease
private final org.eclipse.jetty.io.ByteBufferPool.Lease lease
-
invocationType
private org.eclipse.jetty.util.thread.Invocable.InvocationType invocationType
-
terminated
private java.lang.Throwable terminated
-
stalledEntry
private HTTP2Flusher.Entry stalledEntry
-
-
Constructor Detail
-
HTTP2Flusher
public HTTP2Flusher(HTTP2Session session)
-
-
Method Detail
-
getInvocationType
public org.eclipse.jetty.util.thread.Invocable.InvocationType getInvocationType()
- Specified by:
getInvocationTypein interfaceorg.eclipse.jetty.util.thread.Invocable
-
window
public void window(IStream stream, WindowUpdateFrame frame)
-
prepend
public boolean prepend(HTTP2Flusher.Entry entry)
-
append
public boolean append(HTTP2Flusher.Entry entry)
-
append
public boolean append(java.util.List<HTTP2Flusher.Entry> list)
-
getWindowQueueSize
private int getWindowQueueSize()
-
getFrameQueueSize
public int getFrameQueueSize()
-
process
protected org.eclipse.jetty.util.IteratingCallback.Action process() throws java.lang.Throwable- Specified by:
processin classorg.eclipse.jetty.util.IteratingCallback- Throws:
java.lang.Throwable
-
onFlushed
void onFlushed(long bytes) throws java.io.IOException- Throws:
java.io.IOException
-
succeeded
public void succeeded()
- Specified by:
succeededin interfaceorg.eclipse.jetty.util.Callback- Overrides:
succeededin classorg.eclipse.jetty.util.IteratingCallback
-
finish
private void finish()
-
onCompleteSuccess
protected void onCompleteSuccess()
- Overrides:
onCompleteSuccessin classorg.eclipse.jetty.util.IteratingCallback
-
onCompleteFailure
protected void onCompleteFailure(java.lang.Throwable x)
- Overrides:
onCompleteFailurein classorg.eclipse.jetty.util.IteratingCallback
-
terminate
void terminate(java.lang.Throwable cause)
-
closed
private void closed(HTTP2Flusher.Entry entry, java.lang.Throwable failure)
-
dump
public java.lang.String dump()
- Specified by:
dumpin interfaceorg.eclipse.jetty.util.component.Dumpable
-
dump
public void dump(java.lang.Appendable out, java.lang.String indent) throws java.io.IOException- Specified by:
dumpin interfaceorg.eclipse.jetty.util.component.Dumpable- Throws:
java.io.IOException
-
toString
public java.lang.String toString()
- Overrides:
toStringin classorg.eclipse.jetty.util.IteratingCallback
-
-