use of org.glassfish.grizzly.Connection in project Payara by payara.
the class WSTCPProtocolFilter method handleClose.
@Override
public NextAction handleClose(final FilterChainContext ctx) throws IOException {
final Connection connection = ctx.getConnection();
final SelectionKey selectionKey = ((NIOConnection) connection).getSelectionKey();
try {
if (connector != null) {
connector.notifyConnectionClosed((SocketChannel) selectionKey.channel());
} else {
synchronized (sync) {
if (connector != null) {
connector.notifyConnectionClosed((SocketChannel) selectionKey.channel());
}
}
}
} catch (Exception e) {
}
return ctx.getInvokeAction();
}
Aggregations