public class AgentClient extends AbstractAgentProxy implements Runnable, FactoryManagerHolder
| Modifier and Type | Field and Description |
|---|---|
static long |
DEFAULT_MESSAGE_POLL_FREQUENCY
Default value for "agent-client-message-poll-time"
|
static String |
MESSAGE_POLL_FREQUENCY
Time to wait for new incoming messages before checking if the client is still active
|
logSSH_AUTHSOCKET_ENV_NAME| Constructor and Description |
|---|
AgentClient(FactoryManager manager,
String authSocket) |
AgentClient(FactoryManager manager,
String authSocket,
CloseableExecutorService executor) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
String |
getAuthSocket() |
FactoryManager |
getFactoryManager() |
boolean |
isOpen() |
protected void |
messageReceived(Buffer buffer) |
protected Buffer |
request(Buffer buffer) |
void |
run() |
protected void |
throwException(int code)
transform an APR error number in a more fancy exception
|
String |
toString() |
protected Buffer |
waitForMessageBuffer() |
addIdentity, createBuffer, createBuffer, getChannelType, getExecutorService, getIdentities, prepare, removeAllIdentities, removeIdentity, setChannelType, signdebug, 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, waitresolveLocalIdentitypublic static final String MESSAGE_POLL_FREQUENCY
public static final long DEFAULT_MESSAGE_POLL_FREQUENCY
public AgentClient(FactoryManager manager, String authSocket) throws IOException
IOExceptionpublic AgentClient(FactoryManager manager, String authSocket, CloseableExecutorService executor) throws IOException
IOExceptionpublic FactoryManager getFactoryManager()
getFactoryManager in interface FactoryManagerHolderFactoryManagerpublic String getAuthSocket()
public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in interface Channelclose in class AbstractAgentProxyIOExceptionprotected Buffer request(Buffer buffer) throws IOException
request in class AbstractAgentProxyIOExceptionprotected Buffer waitForMessageBuffer() throws IOException
IOExceptionprotected void throwException(int code)
throws IOException
code - APR error codeIOException - the produced exception for the given APR error numberCopyright © 2008–2021 The Apache Software Foundation. All rights reserved.