예제 #1
0
 /// <summary>
 /// Applies the credentials if they have been set by call <see cref="Cluster.Authenticate"/>.
 /// </summary>
 /// <param name="request">The request.</param>
 protected void ApplyCredentials(IQueryRequest request)
 {
     if (ClientConfiguration.HasCredentials)
     {
         var creds = ClientConfiguration.GetCredentials(AuthContext.ClusterN1Ql);
         foreach (var cred in creds)
         {
             request.AddCredentials(cred.Key, cred.Value, false);
         }
     }
 }
예제 #2
0
 /// <summary>
 /// Applies the credentials if they have been set by call <see cref="Cluster.Authenticate"/>.
 /// </summary>
 /// <param name="request">The request.</param>
 private void ApplyCredentials(IQueryRequest request)
 {
     if (_clientConfig.HasCredentials)
     {
         var creds = _clientConfig.GetCredentials(AuthContext.ClusterN1Ql);
         foreach (var cred in creds)
         {
             request.AddCredentials(cred.Key, cred.Value, false);
         }
     }
 }