Package com.couchbase.client.core.message.kv

Examples of com.couchbase.client.core.message.kv.GetBucketConfigRequest


                Subscription subscription = environment.scheduler().createWorker().schedulePeriodically(new Action0() {
                    @Override
                    public void call() {
                        final InetAddress hostname = config.nodes().get(0).hostname();
                        cluster()
                            .<GetBucketConfigResponse>send(new GetBucketConfigRequest(config.name(), hostname))
                            .subscribe(new Action1<GetBucketConfigResponse>() {
                                @Override
                                public void call(GetBucketConfigResponse res) {
                                    String rawConfig = res.content().toString(CharsetUtil.UTF_8).replace("$HOST",
                                        hostname.getHostName());
View Full Code Here


                @Override
                public void call(final BucketConfig config) {
                    InetAddress hostname = config.nodes().get(0).hostname();

                    cluster()
                        .<GetBucketConfigResponse>send(new GetBucketConfigRequest(config.name(), hostname))
                        .map(new Func1<GetBucketConfigResponse, String>() {
                            @Override
                            public String call(GetBucketConfigResponse response) {
                                String raw = response.content().toString(CharsetUtil.UTF_8);
                                return raw.replace("$HOST", response.hostname().getHostName());
View Full Code Here

        if (!env().bootstrapCarrierEnabled()) {
            LOGGER.info("Carrier Bootstrap manually disabled.");
            return Observable.error(new ConfigurationException("Carrier Bootstrap disabled through configuration."));
        }
        return cluster()
            .<GetBucketConfigResponse>send(new GetBucketConfigRequest(bucket, hostname))
            .map(new Func1<GetBucketConfigResponse, String>() {
                @Override
                public String call(GetBucketConfigResponse response) {
                    if (!response.status().isSuccess()) {
                        throw new IllegalStateException("Bucket config response did not return with success.");
View Full Code Here

TOP

Related Classes of com.couchbase.client.core.message.kv.GetBucketConfigRequest

Copyright © 2018 www.massapicom. 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.