Package com.basho.riak.client.raw.http

Examples of com.basho.riak.client.raw.http.HTTPClientAdapter


    /**
     * Wraps a {@link HTTPClientAdapter} connecting to 127.0.0.1:8098/riak in a {@link DefaultRiakClient}
     * @return a default configuration {@link DefaultRiakClient} delegating to the HTTP client
     */
    public static IRiakClient httpClient() throws RiakException {
        final RawClient client = new HTTPClientAdapter(DEFAULT_RIAK_URL);
        return new DefaultRiakClient(client);
    }
View Full Code Here


     *            a String of the url for Riak's REST iterface
     * @return a default configuration {@link DefaultRiakClient} delegating to
     *         the HTTP client
     */
    public static IRiakClient httpClient(String url) throws RiakException {
        final RawClient client = new HTTPClientAdapter(url);
        return new DefaultRiakClient(client);
    }
View Full Code Here

     * Wraps the given {@link com.basho.riak.client.http.RiakClient} in a {@link DefaultRiakClient}
     * @param delegate the http.{@link com.basho.riak.client.http.RiakClient} to wrap.
     * @return a {@link DefaultRiakClient} that delegates to <code>delegate</code>
     */
    public static IRiakClient httpClient(com.basho.riak.client.http.RiakClient delegate) throws RiakException {
        final RawClient client = new HTTPClientAdapter(delegate);
        return new DefaultRiakClient(client);
    }
View Full Code Here

        switch (location.getTransport()) {
        case PB:
            client = new PBClientAdapter(location.getHost(), location.getPort());
            break;
        case HTTP:
            client = new HTTPClientAdapter(location.asString());
            break;
        default:
            throw new IOException("Unknown Transport");
        }
        return client;
View Full Code Here

TOP

Related Classes of com.basho.riak.client.raw.http.HTTPClientAdapter

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.