public class ChannelSession extends AbstractClientChannel
AbstractChannel.GracefulChannelCloseable, AbstractChannel.GracefulState, AbstractChannel.PacketValidatorAbstractCloseable.StateAttributeRepository.AttributeKey<T>StreamingChannel.Streaming| Modifier and Type | Field and Description |
|---|---|
protected Future<?> |
pumper |
protected CloseableExecutorService |
pumperService |
asyncErr, asyncIn, asyncOut, err, exitSignalHolder, exitStatusHolder, in, invertedErr, invertedIn, invertedOut, opened, openFailureLang, openFailureMsg, openFailureReason, openFuture, out, redirectErrorStream, streamingchannelListenerProxy, channelListeners, closeSignaled, DEFAULT_PACKET_VALIDATOR, eofReceived, eofSent, gracefulFuture, gracefulState, initialized, RESPONSE_BUFFER_GROWTH_FACTOR, service, unregisterSignaledcloseFuture, futureLock, statelogCHANNEL_EXEC, CHANNEL_SHELL, CHANNEL_SUBSYSTEMEMPTYNONE| Constructor and Description |
|---|
ChannelSession() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
closeImmediately0() |
protected void |
doOpen() |
protected Closeable |
getInnerCloseable() |
protected RequestHandler.Result |
handleInternalRequest(String req,
boolean wantReply,
Buffer buffer)
Called by
AbstractChannel.handleUnknownChannelRequest(String, boolean, Buffer) in order to allow channel request
handling if none of the registered handlers processed the request - last chance. |
protected RequestHandler.Result |
handleXonXoff(Buffer buffer,
boolean wantReply) |
protected void |
pumpInputStream() |
protected int |
securedRead(InputStream in,
int maxChunkSize,
byte[] buf,
int off,
int len) |
protected void |
sendEnvVariables(Session session) |
Object |
setEnv(String key,
Object value) |
addChannelSignalRequestHandlers, doWriteData, doWriteExtendedData, getAsyncErr, getAsyncIn, getAsyncOut, getChannelState, getChannelType, getErr, getExitSignal, getExitStatus, getIn, getInvertedErr, getInvertedIn, getInvertedOut, getOut, getStreaming, handleOpenFailure, handleOpenSuccess, handleWindowAdjust, isRedirectErrorStream, mayWrite, open, open, setErr, setIn, setOut, setRedirectErrorStream, setStreaming, updateCurrentChannelState, waitForaddChannelListener, addPendingRequest, addRequestHandler, attributeKeys, clearAttributes, computeAttributeIfAbsent, configureWindow, getAttribute, getAttributesCount, getChannelId, getChannelListenerProxy, getChannelStreamWriterResolver, getExecutorService, getLocalWindow, getPacketValidator, getParentPropertyResolver, getProperties, getRecipient, getRemoteWindow, getRequestHandlers, getSession, handleChannelRegistrationResult, handleChannelRequest, handleChannelUnregistration, handleClose, handleData, handleEof, handleExtendedData, handleFailure, handleRequest, handleSuccess, handleUnknownChannelRequest, init, invokeChannelSignaller, isEofSent, isEofSignalled, isInitialized, notifyStateChanged, notifyStateChanged, preClose, removeAttribute, removeChannelListener, removePendingRequest, removeRequestHandler, resolveChannelStreamWriterResolver, sendEof, sendResponse, sendWindowAdjust, setAttribute, setChannelStreamWriterResolver, setPacketValidator, setRecipient, signalChannelClosed, signalChannelClosed, signalChannelInitialized, signalChannelInitialized, signalChannelOpenFailure, signalChannelOpenFailure, signalChannelOpenSuccess, signalChannelOpenSuccess, toString, validateIncomingDataSize, writePacketdoCloseGracefully, doCloseImmediatelyaddCloseFutureListener, builder, close, getFutureLock, isClosed, isClosing, removeCloseFutureListenerdebug, debug, debug, debug, debug, error, error, error, error, error, getSimplifiedLogger, info, info, warn, warn, warn, warn, warn, warn, warn, warnclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetClientSession, validateCommandExitStatusCode, waitForaddRequestHandler, addRequestHandlers, getLocalWindow, getRecipient, getRemoteWindow, getRequestHandlers, handleChannelRegistrationResult, handleChannelUnregistration, handleClose, handleData, handleEof, handleExtendedData, handleFailure, handleRequest, handleSuccess, init, isEofSignalled, isInitialized, removeRequestHandler, removeRequestHandlers, resolveAttribute, resolveAttribute, writePacketgetSession, getSessionContextgetChannelIdaddChannelListener, getChannelListenerProxy, removeChannelListenergetBoolean, getBooleanProperty, getCharset, getInteger, getIntProperty, getLong, getLongProperty, getObject, getParentPropertyResolver, getProperties, getString, getStringProperty, isEmpty, isEmptyclearAttributes, computeAttributeIfAbsent, removeAttribute, setAttributeattributeKeys, getAttribute, getAttributesCount, ofAttributesMap, ofKeyValuePairgetChannelStreamWriterResolver, resolveChannelStreamWriter, resolveChannelStreamWriterResolver, setChannelStreamWriterResolveraddCloseFutureListener, close, close, close, getMaxCloseWaitTime, isClosed, isClosing, isOpen, removeCloseFutureListenerprotected CloseableExecutorService pumperService
protected Future<?> pumper
protected void doOpen()
throws IOException
doOpen in class AbstractClientChannelIOExceptionprotected RequestHandler.Result handleInternalRequest(String req, boolean wantReply, Buffer buffer) throws IOException
AbstractChannelAbstractChannel.handleUnknownChannelRequest(String, boolean, Buffer) in order to allow channel request
handling if none of the registered handlers processed the request - last chance.handleInternalRequest in class AbstractChannelreq - The request typewantReply - Whether reply is requestedbuffer - The Buffer containing extra request-specific datanull or Unsupported and reply is required then a
failure message will be sentIOException - If failed to process the request internallyprotected RequestHandler.Result handleXonXoff(Buffer buffer, boolean wantReply) throws IOException
IOExceptionprotected Closeable getInnerCloseable()
getInnerCloseable in class AbstractClientChannelprotected void closeImmediately0()
protected void pumpInputStream()
protected int securedRead(InputStream in, int maxChunkSize, byte[] buf, int off, int len) throws IOException
IOExceptionpublic Object setEnv(String key, Object value)
key - The (never null) key (Note: may be empty...)value - The value to set - if null then the pre-existing value for the key (if any) is
removed.null if no previous value set for the key.protected void sendEnvVariables(Session session) throws IOException
IOExceptionCopyright © 2008–2024 The Apache Software Foundation. All rights reserved.