示例#1
0
 public HBaseClient(ClusterCredentials credentials, RequestOptions globalRequestOptions = null,
                    ILoadBalancer loadBalancer = null)
 {
     _globalRequestOptions = globalRequestOptions ?? RequestOptions.GetDefaultOptions();
     _globalRequestOptions.Validate();
     if (credentials != null) // gateway mode
     {
         _requester = new GatewayWebRequester(credentials);
     }
     else // vnet mode
     {
         _requester = new VNetWebRequester(loadBalancer);
     }
 }
示例#2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="HBaseClient" /> class.
 /// </summary>
 /// <param name="credentials">The credentials.</param>
 public HBaseClient(ClusterCredentials credentials)
     : this(credentials, RequestOptions.GetDefaultOptions())
 {
 }