private AzureBlockBlobFileSystemConfigurationProvider(
     [Parameter(typeof(AzureStorageConnectionString))] string connectionString,
     IAzureBlobRetryPolicy retryPolicy)
 {
     _configuration = TangFactory.GetTang().NewConfigurationBuilder()
         .BindImplementation(GenericType<IFileSystem>.Class, GenericType<AzureBlockBlobFileSystem>.Class)
         .BindImplementation(typeof(IAzureBlobRetryPolicy), retryPolicy.GetType())
         .BindStringNamedParam<AzureStorageConnectionString>(connectionString)
         .BindSetEntry<EvaluatorConfigurationProviders, AzureBlockBlobFileSystemConfigurationProvider, IConfigurationProvider>()
         .Build();
 }
 private AzureBlockBlobFileSystemConfigurationProvider(
     [Parameter(typeof(AzureStorageConnectionString))] string connectionString,
     IAzureBlobRetryPolicy retryPolicy)
 {
     _configuration = TangFactory.GetTang().NewConfigurationBuilder()
                      .BindImplementation(GenericType <IFileSystem> .Class, GenericType <AzureBlockBlobFileSystem> .Class)
                      .BindImplementation(typeof(IAzureBlobRetryPolicy), retryPolicy.GetType())
                      .BindStringNamedParam <AzureStorageConnectionString>(connectionString)
                      .BindSetEntry <EvaluatorConfigurationProviders, AzureBlockBlobFileSystemConfigurationProvider, IConfigurationProvider>()
                      .Build();
 }
Пример #3
0
        private AzureCloudBlobClient([Parameter(typeof(AzureBlobStorageAccountName))] string accountName,
                                     [Parameter(typeof(AzureBlobStorageAccountKey))] string accountKey,
                                     IAzureBlobRetryPolicy retryPolicy)
        {
            var connectionString = string.Format(AzureBlobConnectionFormat, accountName, accountKey);

            _client = CloudStorageAccount.Parse(connectionString).CreateCloudBlobClient();
            _client.DefaultRequestOptions.RetryPolicy = retryPolicy;
            _requestOptions = new BlobRequestOptions()
            {
                RetryPolicy = retryPolicy
            };
        }
 private AzureBlobFileSystemConfigurationProvider(
     [Parameter(typeof(AzureBlobStorageAccountName))] string accountName,
     [Parameter(typeof(AzureBlobStorageAccountKey))] string accountKey,
     IAzureBlobRetryPolicy retryPolicy)
 {
     _configuration = TangFactory.GetTang().NewConfigurationBuilder()
                      .BindImplementation(GenericType <IFileSystem> .Class, GenericType <AzureBlobFileSystem> .Class)
                      .BindImplementation(typeof(IAzureBlobRetryPolicy), retryPolicy.GetType())
                      .BindStringNamedParam <AzureBlobStorageAccountName>(accountName)
                      .BindStringNamedParam <AzureBlobStorageAccountKey>(accountKey)
                      .BindSetEntry <EvaluatorConfigurationProviders, AzureBlobFileSystemConfigurationProvider, IConfigurationProvider>()
                      .Build();
 }
Пример #5
0
 private AzureCloudBlobClient([Parameter(typeof(AzureStorageConnectionString))] string connectionString,
                              IAzureBlobRetryPolicy retryPolicy)
 {
     _client = CloudStorageAccount.Parse(connectionString).CreateCloudBlobClient();
     _client.DefaultRequestOptions.RetryPolicy = retryPolicy;
 }
Пример #6
0
 private AzureCloudBlobClient([Parameter(typeof(AzureStorageConnectionString))] string connectionString,
                              IAzureBlobRetryPolicy retryPolicy)
 {
     _client = CloudStorageAccount.Parse(connectionString).CreateCloudBlobClient();
     _client.DefaultRequestOptions.RetryPolicy = retryPolicy;
 }