Example usage for io.netty.resolver DefaultAddressResolverGroup INSTANCE

List of usage examples for io.netty.resolver DefaultAddressResolverGroup INSTANCE

Introduction

In this page you can find the example usage for io.netty.resolver DefaultAddressResolverGroup INSTANCE.

Prototype

DefaultAddressResolverGroup INSTANCE

To view the source code for io.netty.resolver DefaultAddressResolverGroup INSTANCE.

Click Source Link

Usage

From source file:com.kevinherron.GatewayHook.java

@Override
public void shutdown() {
    logger.info("shutdown()");

    try {/* w  w w . j  ava2  s .  c o m*/
        eventLoop.shutdownGracefully().get();
    } catch (Throwable e) {
        logger.error("Error waiting for event loop shutdown: {}", e.getMessage(), e);
    }
    try {
        GlobalEventExecutor.INSTANCE.shutdownGracefully().get();
    } catch (Throwable e) {
        logger.error("Error waiting for GlobalEventExecutor shutdown: {}", e.getMessage(), e);
    }
    try {
        DefaultAddressResolverGroup.INSTANCE.close();
    } catch (Throwable e) {
        logger.error("Error closing DefaultAddressResolverGroup: {}", e.getMessage(), e);
    }
    InternalThreadLocalMap.destroy();
    FastThreadLocal.removeAll();
}

From source file:com.relayrides.pushy.apns.ApnsClient.java

License:Open Source License

/**
 * Sets the proxy handler factory to be used to construct proxy handlers when establishing a new connection to the
 * APNs gateway. Proxy handlers are added to the beginning of the client's pipeline. A client's proxy handler
 * factory may be {@code null}, in which case the client will connect to the gateway directly and will not use a
 * proxy. By default, clients will not use a proxy.
 *
 * @param proxyHandlerFactory the proxy handler factory to be used to construct proxy handlers, or {@code null} if
 * this client should not use a proxy/*  w w w . ja  va  2s. c  o  m*/
 *
 * @since 0.6
 */
protected void setProxyHandlerFactory(final ProxyHandlerFactory proxyHandlerFactory) {
    this.proxyHandlerFactory = proxyHandlerFactory;
    this.bootstrap.resolver(proxyHandlerFactory == null ? DefaultAddressResolverGroup.INSTANCE
            : NoopAddressResolverGroup.INSTANCE);
}

From source file:io.vertx.core.impl.resolver.DefaultResolverProvider.java

License:Open Source License

@Override
public AddressResolverGroup<InetSocketAddress> resolver(AddressResolverOptions options) {
    return DefaultAddressResolverGroup.INSTANCE;
}