Search in sources :

Example 1 with ServerChannel

use of org.jboss.netty.channel.ServerChannel in project databus by linkedin.

the class HttpRelay method disconnectDBusClients.

public synchronized void disconnectDBusClients(Channel exceptThis) {
    LOG.info("disconnectDBusClients");
    if (_httpChannelGroup != null) {
        LOG.info("Total " + _httpChannelGroup.size() + " channels");
        for (Channel channel : _httpChannelGroup) {
            // Keep the server channel and REST channel
            if ((channel instanceof ServerChannel) || (exceptThis != null && channel.getId().equals(exceptThis.getId()))) {
                LOG.info("Skipping closing channel" + channel.getId());
            } else {
                LOG.info("closing channel" + channel.getId());
                channel.close();
            }
        }
    }
}
Also used : ServerChannel(org.jboss.netty.channel.ServerChannel) Channel(org.jboss.netty.channel.Channel) ServerChannel(org.jboss.netty.channel.ServerChannel)

Aggregations

Channel (org.jboss.netty.channel.Channel)1 ServerChannel (org.jboss.netty.channel.ServerChannel)1