Package org.eclipse.jetty.http2.server
Class HttpTransportOverHTTP2.TransportCallback
- java.lang.Object
-
- org.eclipse.jetty.http2.server.HttpTransportOverHTTP2.TransportCallback
-
- All Implemented Interfaces:
org.eclipse.jetty.util.Callback
,org.eclipse.jetty.util.thread.Invocable
- Enclosing class:
- HttpTransportOverHTTP2
private class HttpTransportOverHTTP2.TransportCallback extends java.lang.Object implements org.eclipse.jetty.util.Callback
Callback that controls sends initiated by the transport, by eventually notifying a nested callback.
There are 3 sources of concurrency after a send is initiated:
- the completion of the send operation, either success or failure
- an asynchronous failure coming from the read side such as a stream being reset, or the connection being closed
- an asynchronous idle timeout
- See Also:
HttpTransportOverHTTP2.State
-
-
Field Summary
Fields Modifier and Type Field Description private org.eclipse.jetty.util.Callback
_callback
private boolean
_commit
private java.lang.Throwable
_failure
private HttpTransportOverHTTP2.State
_state
-
Constructor Summary
Constructors Modifier Constructor Description private
TransportCallback()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private void
abort(java.lang.Throwable failure)
void
failed(java.lang.Throwable failure)
org.eclipse.jetty.util.thread.Invocable.InvocationType
getInvocationType()
private boolean
idleTimeout(java.lang.Throwable failure)
private void
reset(java.lang.Throwable failure)
private void
send(org.eclipse.jetty.util.Callback callback, boolean commit, java.util.function.Consumer<org.eclipse.jetty.util.Callback> sendFrame)
private java.lang.Throwable
sending(org.eclipse.jetty.util.Callback callback, boolean commit)
void
succeeded()
-
-
-
Field Detail
-
_state
private HttpTransportOverHTTP2.State _state
-
_callback
private org.eclipse.jetty.util.Callback _callback
-
_commit
private boolean _commit
-
_failure
private java.lang.Throwable _failure
-
-
Method Detail
-
reset
private void reset(java.lang.Throwable failure)
-
send
private void send(org.eclipse.jetty.util.Callback callback, boolean commit, java.util.function.Consumer<org.eclipse.jetty.util.Callback> sendFrame)
-
abort
private void abort(java.lang.Throwable failure)
-
sending
private java.lang.Throwable sending(org.eclipse.jetty.util.Callback callback, boolean commit)
-
succeeded
public void succeeded()
- Specified by:
succeeded
in interfaceorg.eclipse.jetty.util.Callback
-
failed
public void failed(java.lang.Throwable failure)
- Specified by:
failed
in interfaceorg.eclipse.jetty.util.Callback
-
idleTimeout
private boolean idleTimeout(java.lang.Throwable failure)
-
getInvocationType
public org.eclipse.jetty.util.thread.Invocable.InvocationType getInvocationType()
- Specified by:
getInvocationType
in interfaceorg.eclipse.jetty.util.thread.Invocable
-
-