Examples of UnframedClientConnector


Examples of com.facebook.nifty.client.UnframedClientConnector

    @Override
    public ListenableFuture<HiveMetastore> getClientForHostAsFuture(final HostAndPort hostAndPort, final boolean framed)
    {
        final NiftyClientConnector<? extends NiftyClientChannel> clientConnector = framed
            ? new FramedClientConnector(hostAndPort)
            : new UnframedClientConnector(hostAndPort);

        return thriftClient.open(clientConnector);
    }
View Full Code Here

Examples of com.facebook.nifty.client.UnframedClientConnector

                            switch (config.transport) {
                                case FRAMED:
                                    connector = new FramedClientConnector(HostAndPort.fromParts(config.serverAddress, config.serverPort));
                                    break;
                                case UNFRAMED:
                                    connector = new UnframedClientConnector(HostAndPort.fromParts(config.serverAddress, config.serverPort));
                                    break;
                                default:
                                    throw new IllegalStateException("Unknown transport");
                            }
                            binder.bind(channelConnectorType).toInstance(connector);
View Full Code Here

Examples of com.facebook.nifty.client.UnframedClientConnector

                            switch (config.transport) {
                                case FRAMED:
                                    connector = new FramedClientConnector(HostAndPort.fromParts(config.serverAddress, config.serverPort));
                                    break;
                                case UNFRAMED:
                                    connector = new UnframedClientConnector(HostAndPort.fromParts(config.serverAddress, config.serverPort));
                                    break;
                                default:
                                    throw new IllegalStateException("Unknown transport");
                            }
                            binder.bind(channelConnectorType).toInstance(connector);
View Full Code Here

Examples of com.facebook.nifty.client.UnframedClientConnector

            Class<T> clientType,
            int servicePort)
            throws Exception
    {
        return clientManager.createClient(
                new UnframedClientConnector(HostAndPort.fromParts("localhost", servicePort)),
                clientType);
    }
View Full Code Here

Examples of com.facebook.nifty.client.UnframedClientConnector

            Class<T> clientType,
            int servicePort)
            throws Exception
    {
        return clientManager.createClient(
                new UnframedClientConnector(HostAndPort.fromParts("localhost", servicePort)),
                clientType);
    }
View Full Code Here

Examples of com.facebook.nifty.client.UnframedClientConnector

            Class<T> clientType,
            int servicePort)
            throws Exception
    {
        return clientManager.createClient(
                new UnframedClientConnector(HostAndPort.fromParts("localhost", servicePort)),
                clientType);
    }
View Full Code Here

Examples of com.facebook.nifty.client.UnframedClientConnector

                            switch (config.transport) {
                                case FRAMED:
                                    connector = new FramedClientConnector(HostAndPort.fromParts(config.serverAddress, config.serverPort));
                                    break;
                                case UNFRAMED:
                                    connector = new UnframedClientConnector(HostAndPort.fromParts(config.serverAddress, config.serverPort));
                                    break;
                                default:
                                    throw new IllegalStateException("Unknown transport");
                            }
                            binder.bind(channelConnectorType).toInstance(connector);
View Full Code Here

Examples of com.facebook.nifty.client.UnframedClientConnector

        while (client == null) {
            try {
                final HostAndPort hostAndPort = getNextHostAndPort();
                final NiftyClientConnector<? extends NiftyClientChannel> clientConnector = config.isFramed()
                    ? new FramedClientConnector(hostAndPort)
                    : new UnframedClientConnector(hostAndPort);

                client = thriftClient.open(clientConnector).get();
                if (!clientHolder.compareAndSet(null, client)) {
                    client.close();
                    client = clientHolder.get();
View Full Code Here

Examples of com.facebook.nifty.client.UnframedClientConnector

            Class<T> clientType,
            int servicePort)
            throws Exception
    {
        return clientManager.createClient(
                new UnframedClientConnector(HostAndPort.fromParts("localhost", servicePort)),
                clientType);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.