Example #1
0
 // Constructor for testing purpose.
 public StorageManager(
     ITableClient tableClient,
     ITable table)
 {
     this.tableClient = tableClient;
     this.table       = table;
 }
 protected ReactivePlatformClientBase(IReactivePlatform platform)
 {
     _platform         = platform ?? throw new ArgumentNullException(nameof(platform));
     _queryCoordinator = platform.QueryCoordinator.GetInstance <IRemotingReactiveServiceConnection>();
     _messageRouter    = GetMessageRouter(platform);
     _tableClient      = GetTableClient(platform);
 }
Example #3
0
 public GroupRepository(
     ITableClient <Group> repository,
     IUserRepository userRepository)
 {
     this.repository     = repository;
     this.userRepository = userRepository;
 }
Example #4
0
        // Default constructor.
        public StorageManager(string tableName)
        {
            var storageAccount = CloudStorageAccount.Parse(ConfigurationManager.ConnectionStrings["RulesEngineStorageAccountConnectionString"].ConnectionString);

            this.tableClient = new TableClient(storageAccount);
            this.table       = this.tableClient.GetTableReference(tableName);
        }
Example #5
0
 public ListRepository(
     ITableClient <List> client,
     ITableClient <Group> groupClient,
     IItemRepository itemsRepository)
 {
     this.client          = client;
     this.groupClient     = groupClient;
     this.itemsRepository = itemsRepository;
 }
        public RecordSearchComposition(ITableClient client,
                                       string tableName,
                                       IEnumerable <IRecordMappingConfig <TMain> > mappings, IEnumerable <object> validSearches)
        {
            _tableName     = tableName;
            _mappings      = mappings;
            _client        = client;
            _validSearches = validSearches;

            client.CreateTableIfNotExist(tableName);
        }
        /// <summary>
        /// Creates a new Azure metadata service provider using the cloud table client provided.
        /// </summary>
        /// <param name="tableClient">The cloud table client.</param>
        /// <param name="storageResolver">The table address and partition key resolver.</param>
        public AzureMetadataServiceProvider(ITableClient tableClient, IStorageResolver storageResolver)
        {
            var defaultClientBackoff = TimeSpan.FromMilliseconds(100);
            var maxAttempts          = 3;

            var requestOptions = new TableRequestOptions
            {
                RetryPolicy = new ExponentialRetry(defaultClientBackoff, maxAttempts)
            };

            Provider = new AzureMetadataQueryProvider(tableClient, storageResolver, requestOptions);
        }
Example #8
0
        public static async void BindToTableClientAndAddEntityFunc(
            [ApiHubTable("AzureWebJobsSql")]
            ITableClient tableClient)
        {
            var defaultDataSet = tableClient.GetDataSetReference();
            var table          = defaultDataSet.GetTableReference <SampleEntity>("table1");

            await table.CreateEntityAsync(
                new SampleEntity
            {
                Id   = 1,
                Text = "foo"
            });
        }
 public StorageManager(ITableClient tables, IBlobClient blobs)
 {
     _tables = tables;
 }
 public AssignmentsService(ITableClient tableClient)
 {
     this.tableClient = tableClient;
 }
 public DeleteSpeakerCommandHandler(ITableClient tableClient)
 {
     _tableClient = tableClient;
 }
Example #12
0
 public UsergroupQueryHandler(ITableClient tableClient)
 {
     _tableClient = tableClient;
 }
Example #13
0
 public ProjectsService(ITableClient tableClient)
 {
     this.tableClient = tableClient;
 }
 public EventQueryHandler(ITableClient tableClient)
 {
     _tableClient = tableClient;
 }
Example #15
0
 public RecordSearchComposer(ITableClient client)
 {
     _client = client;
 }
Example #16
0
 public RecordSearchConfig(ITableClient client, string tableName)
 {
     _tableName = tableName;
     _client    = client;
 }
Example #17
0
 /// <summary>
 /// Creates a new reactive metadata service proxy using a table client.
 /// </summary>
 /// <param name="tableClient">The table storage client.</param>
 /// <param name="storageResolver">The table address and partition key resolver.</param>
 public AzureReactiveMetadataProxy(ITableClient tableClient, IStorageResolver storageResolver)
     : this(new AzureMetadataServiceProvider(tableClient, storageResolver), new ReactiveExpressionServices(typeof(IReactiveClientProxy)))
 {
 }
Example #18
0
 public NewsletterQueryHandler(ITableClient tableClient)
 {
     _tableClient = tableClient;
 }
Example #19
0
 public static void Func2(
     [ApiHubTable("AzureWebJobsSql", TableName = "table1")]
     ITableClient tableClient)
 {
 }
Example #20
0
 public static void Func1(
     [ApiHubTable("AzureWebJobsSql")]
     out ITableClient tableClient)
 {
     tableClient = null;
 }
 public static void BindToTableClient(
     [ApiHubTable("AzureWebJobsSql")]
     ITableClient tableClient)
 {
     // Use the table client.
 }
 /// <summary>
 /// Instantiates the query provider with an empty connection string, which signals to use the developer emulator.
 /// </summary>
 /// <param name="tableClient">The cloud table client.</param>
 /// <param name="storageResolver">The table address and partition key resolver.</param>
 /// <param name="requestOptions">Table request options, including retry policy.</param>
 public AzureMetadataQueryProvider(ITableClient tableClient, IStorageResolver storageResolver, TableRequestOptions requestOptions)
 {
     _tableClient     = tableClient ?? throw new ArgumentNullException(nameof(tableClient));
     _storageResolver = storageResolver ?? throw new ArgumentNullException(nameof(storageResolver));
     _requestOptions  = requestOptions;
 }
 public CreateUserHandler(ITableClient tableClient)
 {
     _tableClient = tableClient;
 }
Example #24
0
 public SpeakerQueryHandler(ITableClient tableClient)
 {
     _tableClient = tableClient;
 }
Example #25
0
 public ItemRepository(ITableClient <ListItem> client)
 => this.client = client;
Example #26
0
 public UserRepository(ITableClient <User> client, ILogger <UserRepository> logger)
 {
     this.client = client;
     this.logger = logger;
 }
Example #27
0
 public InsertSpeakerCommandHandler(ITableClient tableClient)
 {
     _tableClient = tableClient;
 }