public SocketAddress getPeerAddress() { return remoteConnection.getPeerAddress(); }
void handleDuplicate() { // this method is called when the remote side forgot about us. Our mapping will have been already replaced. // We must not send anything to the peer from here on because things may be in a broken state. // Though this is a best-effort strategy as everything is screwed up in this case anyway. conn.duplicateMessageId(messageId, channel.getRemoteConnection().getPeerAddress()); synchronized (inputStream) { if (! streamClosed) { eofReceived = true; // it wasn't really, but we should act like it was closeSent = true; // we didn't really, but we should act like we did cancelled = true; // just not the usual way... inputStream.pushException(conn.duplicateMessageIdException()); } } }
private void handleAccepted(final StreamConnection accepted, final SslChannel sslChannel, final OptionMap serverOptionMap, final SaslAuthenticationFactory saslAuthenticationFactory) { final RemoteConnection connection = new RemoteConnection(accepted, sslChannel, serverOptionMap, RemoteConnectionProvider.this); final ServerConnectionOpenListener openListener = new ServerConnectionOpenListener(connection, connectionProviderContext, saslAuthenticationFactory, serverOptionMap); accepted.getSinkChannel().setWriteListener(connection.getWriteListener()); log.tracef("Accepted connection from %s to %s", connection.getPeerAddress(), connection.getLocalAddress()); openListener.handleEvent(accepted.getSourceChannel()); } }
connection.setSaslWrapper(SaslWrapper.create(saslServer)); final String peerName = connection.getPeerAddress().getHostName(); final RemoteConnectionHandler connectionHandler = new RemoteConnectionHandler( connectionContext, connection, maxInboundChannels, maxOutboundChannels, AnonymousPrincipal.getInstance(), remoteEndpointName, behavior, authCap, offeredMechanisms, peerName, serverName);
remoteServerName = InetUtils.determineServerName(connection.getPeerAddress().getHostName());
public SocketAddress getPeerAddress() { return remoteConnection.getPeerAddress(); }
void handleDuplicate() { // this method is called when the remote side forgot about us. Our mapping will have been already replaced. // We must not send anything to the peer from here on because things may be in a broken state. // Though this is a best-effort strategy as everything is screwed up in this case anyway. conn.duplicateMessageId(messageId, channel.getRemoteConnection().getPeerAddress()); synchronized (inputStream) { if (! streamClosed) { eofReceived = true; // it wasn't really, but we should act like it was closeSent = true; // we didn't really, but we should act like we did cancelled = true; // just not the usual way... inputStream.pushException(conn.duplicateMessageIdException()); } } }
private void handleAccepted(final StreamConnection accepted, final SslChannel sslChannel, final OptionMap serverOptionMap, final SaslAuthenticationFactory saslAuthenticationFactory) { final RemoteConnection connection = new RemoteConnection(accepted, sslChannel, serverOptionMap, RemoteConnectionProvider.this); final ServerConnectionOpenListener openListener = new ServerConnectionOpenListener(connection, connectionProviderContext, saslAuthenticationFactory, serverOptionMap); accepted.getSinkChannel().setWriteListener(connection.getWriteListener()); log.tracef("Accepted connection from %s to %s", connection.getPeerAddress(), connection.getLocalAddress()); openListener.handleEvent(accepted.getSourceChannel()); } }
connection.setSaslWrapper(SaslWrapper.create(saslServer)); final String peerName = connection.getPeerAddress().getHostName(); final RemoteConnectionHandler connectionHandler = new RemoteConnectionHandler( connectionContext, connection, maxInboundChannels, maxOutboundChannels, AnonymousPrincipal.getInstance(), remoteEndpointName, behavior, authCap, offeredMechanisms, peerName, serverName);
remoteServerName = InetUtils.determineServerName(connection.getPeerAddress().getHostName());