ch.configureBlocking(blocking);
} catch (IOException e) {
LOG.error("Failed to open SocketChannel.", e);
throw new IllegalStateException(e);
}
final Socket sock = ch.socket();
if(rcvbufSize != -1) {
try {
sock.setReceiveBufferSize(rcvbufSize);
} catch (SocketException e) {
LOG.error("Failed to setReceiveBufferSize.", e);