public class ChannelSubsystem extends ChannelSession
AbstractChannel.GracefulChannelCloseable, AbstractChannel.GracefulState
AbstractCloseable.State
ClientChannel.Streaming
AttributeRepository.AttributeKey<T>
Modifier and Type | Field and Description |
---|---|
static boolean |
DEFAULT_REQUEST_SUBSYSTEM_REPLY
Default value for
REQUEST_SUBSYSTEM_REPLY - according to
RFC4254 section 6.5: |
static java.lang.String |
REQUEST_SUBSYSTEM_REPLY
Configure whether reply for the "subsystem&quoot; request is required
|
private java.lang.String |
subsystem |
DEFAULT_INPUT_STREAM_PUMP_CHUNK_SIZE, INPUT_STREAM_PUMP_CHUNK_SIZE
asyncErr, asyncIn, asyncOut, err, exitSignalHolder, exitStatusHolder, in, invertedErr, invertedIn, invertedOut, opened, openFailureLang, openFailureMsg, openFailureReason, openFuture, out, streaming
channelListenerProxy, channelListeners, eofReceived, eofSent, gracefulFuture, gracefulState, initialized, RESPONSE_BUFFER_GROWTH_FACTOR, service
closeFuture, futureLock, state
log
CHANNEL_EXEC, CHANNEL_SHELL, CHANNEL_SUBSYSTEM
EMPTY
NONE
CLOSE_WAIT_TIMEOUT, DEFAULT_CLOSE_WAIT_TIMEOUT
Constructor and Description |
---|
ChannelSubsystem(java.lang.String subsystem) |
Modifier and Type | Method and Description |
---|---|
protected void |
doOpen() |
java.lang.String |
getSubsystem()
The subsystem name
|
void |
handleFailure()
Invoked when
SSH_MSG_CHANNEL_FAILURE received |
void |
handleSuccess()
Invoked when
SSH_MSG_CHANNEL_SUCCESS received |
void |
onClose(java.lang.Runnable run) |
java.lang.String |
toString() |
closeImmediately0, getInnerCloseable, handleInternalRequest, handleXonXoff, pumpInputStream, securedRead
addChannelSignalRequestHandlers, doWriteData, doWriteExtendedData, getAsyncErr, getAsyncIn, getAsyncOut, getChannelState, getChannelType, getErr, getExitSignal, getExitStatus, getIn, getInvertedErr, getInvertedIn, getInvertedOut, getOut, getStreaming, handleOpenFailure, handleOpenSuccess, handleWindowAdjust, open, open, setErr, setIn, setOut, setStreaming, updateCurrentChannelState, waitFor
addChannelListener, addPendingRequest, addRequestHandler, attributeKeys, clearAttributes, computeAttributeIfAbsent, configureWindow, getAttribute, getAttributesCount, getChannelListenerProxy, getChannelStreamPacketWriterResolver, getExecutorService, getId, getLocalWindow, getParentPropertyResolver, getProperties, getRecipient, getRemoteWindow, getRequestHandlers, getSession, handleChannelRequest, handleClose, handleData, handleEof, handleExtendedData, handleRequest, handleUnknownChannelRequest, init, invokeChannelSignaller, isEofSent, isEofSignalled, isInitialized, notifyStateChanged, notifyStateChanged, preClose, removeAttribute, removeChannelListener, removePendingRequest, removeRequestHandler, resolveChannelStreamPacketWriterResolver, sendEof, sendResponse, sendWindowAdjust, setAttribute, setChannelStreamPacketWriterResolver, setRecipient, signalChannelClosed, signalChannelClosed, signalChannelInitialized, signalChannelInitialized, signalChannelOpenFailure, signalChannelOpenFailure, signalChannelOpenSuccess, signalChannelOpenSuccess, validateIncomingDataSize, writePacket
doCloseGracefully, doCloseImmediately
addCloseFutureListener, builder, close, getFutureLock, isClosed, isClosing, removeCloseFutureListener
getSimplifiedLogger
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getClientSession, validateCommandExitStatusCode, waitFor
addRequestHandler, addRequestHandlers, getId, getLocalWindow, getRecipient, getRemoteWindow, getRequestHandlers, handleClose, handleData, handleEof, handleExtendedData, handleRequest, init, isEofSignalled, isInitialized, removeRequestHandler, removeRequestHandlers, resolveAttribute, resolveAttribute
getSession, getSessionContext
addChannelListener, getChannelListenerProxy, removeChannelListener
getBoolean, getBooleanProperty, getCharset, getInteger, getIntProperty, getLong, getLongProperty, getObject, getParentPropertyResolver, getProperties, getString, getStringProperty
clearAttributes, computeAttributeIfAbsent, removeAttribute, setAttribute
attributeKeys, getAttribute, getAttributesCount, ofAttributesMap, ofKeyValuePair
calculatePadLength, writePacket
getChannelStreamPacketWriterResolver, resolveChannelStreamPacketWriter, resolveChannelStreamPacketWriterResolver, setChannelStreamPacketWriterResolver
addCloseFutureListener, close, close, close, getMaxCloseWaitTime, isClosed, isClosing, isOpen, removeCloseFutureListener
public static final java.lang.String REQUEST_SUBSYSTEM_REPLY
public static final boolean DEFAULT_REQUEST_SUBSYSTEM_REPLY
Default value for REQUEST_SUBSYSTEM_REPLY
- according to
RFC4254 section 6.5:
It is RECOMMENDED that the reply to these messages be requested and checked.
private final java.lang.String subsystem
public ChannelSubsystem(java.lang.String subsystem)
subsystem
- The subsystem name for the channel - never null
or emptypublic final java.lang.String getSubsystem()
null
or emptyprotected void doOpen() throws java.io.IOException
doOpen
in class ChannelSession
java.io.IOException
public void handleSuccess() throws java.io.IOException
Channel
SSH_MSG_CHANNEL_SUCCESS
receivedhandleSuccess
in class AbstractChannel
java.io.IOException
- If failed to handle the messagepublic void handleFailure() throws java.io.IOException
Channel
SSH_MSG_CHANNEL_FAILURE
receivedhandleFailure
in class AbstractChannel
java.io.IOException
- If failed to handle the messagepublic void onClose(java.lang.Runnable run)
public java.lang.String toString()
toString
in class AbstractChannel