private class SimpleRpcServer.Listener.Reader extends Object implements Runnable
| Modifier and Type | Field and Description |
|---|---|
private LinkedBlockingQueue<SimpleServerRpcConnection> |
pendingConnections |
private Selector |
readSelector |
| Constructor and Description |
|---|
Reader() |
| Modifier and Type | Method and Description |
|---|---|
void |
addConnection(SimpleServerRpcConnection conn)
Updating the readSelector while it's being used is not thread-safe,
so the connection must be queued.
|
private void |
doRunLoop() |
void |
run() |
private final LinkedBlockingQueue<SimpleServerRpcConnection> pendingConnections
private final Selector readSelector
Reader() throws IOException
IOExceptionprivate void doRunLoop()
public void addConnection(SimpleServerRpcConnection conn) throws IOException
IOExceptionCopyright © 2007–2020 The Apache Software Foundation. All rights reserved.