public HomeController(IAzureSearchService azureSearchService, IPostedItemService postedItemService, ISitemapService sitemapService, IConfigurationService configurationService) : base() { _sitemapService = sitemapService; _azureSearchService = azureSearchService; _postedItemService = postedItemService; _configurationService = configurationService; }
public SearchEventHandler(IAzureSearchService azureSearchService, IContentLoader contentLoader, PageDocumentsProvider <T> pageDocumentsProvider, BlockDocumentsProvider <T> blockDocumentsProvider, IUrlResolver urlResolver) { _azureSearchService = azureSearchService; _contentLoader = contentLoader; _pageDocumentsProvider = pageDocumentsProvider; _blockDocumentsProvider = blockDocumentsProvider; _urlResolver = urlResolver; }
public static async Task <ILogsProcessorBuilder> AddToSearchIndexAsync <TEventDto>( this ILogsProcessorBuilder processorBuilder, IAzureSearchService azureSearchService, string indexName, Predicate <EventLog <TEventDto> > predicate = null) where TEventDto : class, new() { var indexer = await azureSearchService.CreateEventIndexer <TEventDto>(indexName).ConfigureAwait(false); processorBuilder.DisposeOnProcessorDisposing(indexer); return(processorBuilder.AddToSearchIndex(indexer, predicate: predicate)); }
public static async Task <ILogsProcessorBuilder> AddToSearchIndexAsync <TEventDto, TSearchDocument>( this ILogsProcessorBuilder processorBuilder, IAzureSearchService azureSearchService, Index azureIndex, Func <EventLog <TEventDto>, TSearchDocument> mappingFunc, Predicate <EventLog <TEventDto> > predicate = null) where TEventDto : class, new() where TSearchDocument : class, new() { var indexer = await azureSearchService.CreateEventIndexer(azureIndex, mappingFunc).ConfigureAwait(false); processorBuilder.DisposeOnProcessorDisposing(indexer); return(processorBuilder.AddToSearchIndex(indexer, predicate)); }
public AzureEventIndexingProcessor( IWeb3 web3, IAzureSearchService searchService, IEventFunctionProcessor functionProcessor, Func <BigInteger, BigInteger?, IBlockProgressService> blockProgressServiceCallBack = null, uint maxBlocksPerBatch = 2, IEnumerable <NewFilterInput> filters = null, uint minimumBlockConfirmations = 0) : base(web3, searchService, functionProcessor, blockProgressServiceCallBack, maxBlocksPerBatch, filters, minimumBlockConfirmations) { AzureSearchService = searchService; }
public AzureEventIndexingProcessor( IBlockchainProxyService blockchainProxyService, IAzureSearchService searchService, IEventFunctionProcessor functionProcessor, Func <ulong, ulong?, IBlockProgressService> blockProgressServiceCallBack = null, uint maxBlocksPerBatch = 2, IEnumerable <NewFilterInput> filters = null, uint minimumBlockConfirmations = 0) : base(blockchainProxyService, searchService, functionProcessor, blockProgressServiceCallBack, maxBlocksPerBatch, filters, minimumBlockConfirmations) { AzureSearchService = searchService; }
private async Task ClearDown( EventProcessingConfigContext repo, AzureTablesRepositoryFactory cloudTableSetup, IAzureSearchService searchService, AzureStorageQueueFactory subscriberQueueFactory, AzureTablesSubscriberRepositoryFactory azureTablesSubscriberRepositoryFactory) { foreach (var index in repo.SubscriberSearchIndexes) { await searchService.DeleteIndexAsync(index.Name); } foreach (var queue in repo.SubscriberSearchIndexes) { await subscriberQueueFactory.DeleteQueueAsync(queue.Name); } await cloudTableSetup.GetCountersTable().DeleteIfExistsAsync(); await azureTablesSubscriberRepositoryFactory.DeleteTablesAsync(); }
public IndexDefinitionHandler(IAzureSearchService azureSearchService, IIndexSpecificationProvider indexSpecificationProvider) { _azureSearchService = azureSearchService; _indexSpecificationProvider = indexSpecificationProvider; }
public static async Task <DocumentIndexResult> IndexAsync <T>(this IAzureSearchService azureSearchService, T document, string indexName = null) where T : SearchDocument { return(await azureSearchService.IndexAsync(new [] { document }, indexName)); }
public static DocumentIndexResult Index <T>(this IAzureSearchService azureSearchService, T document, string indexName = null) where T : SearchDocument { return(azureSearchService.Index(new[] { document }, indexName)); }
public PageSearchProvider(IAzureSearchService azureSearchService, IContentLanguageAccessor contentLanguageAccessor) : base(azureSearchService, contentLanguageAccessor) { }
public static IReadOnlyCollection <SearchResult <T> > SearchBatch <T>(this IAzureSearchService searchService, AzureSearchQuery query, string indexName = null, int batchSize = 1000) where T : SearchDocument { return(searchService.SearchBatchAsync <T>(query, indexName, batchSize).GetAwaiter().GetResult()); }
public PostedItemsController(IAzureSearchService azureSearchService, IPostedItemService postedItemService) { _azureSearchService = azureSearchService; _postedItemService = postedItemService; }
public AzureSearchDemoController(ILogger logger, IAzureSearchService azureSearchService, ICustomConfigurationSettings customConfigurationSettings) { _logger = logger; _azureSearchService = azureSearchService; _CustomConfigurationSettings = customConfigurationSettings; }
public AzureSubscriberSearchIndexFactory( IAzureSearchService searchService) { SearchService = searchService; }
protected ContentSearchProviderBase(IAzureSearchService azureSearchService, IContentLanguageAccessor contentLanguageAccessor) { _azureSearchService = azureSearchService; _contentLanguageAccessor = contentLanguageAccessor; }
public ContentIndexer(IContentLoader contentLoader, IAzureSearchService azureSearchService, IContentDocumentBuilder <T> documentBuilder) { _contentLoader = contentLoader; _azureSearchService = azureSearchService; _documentBuilder = documentBuilder; }
public SearchController(IAzureSearchService azureSearchService) { _azureSearchService = azureSearchService; }
public static async Task <IReadOnlyCollection <SearchResult <T> > > SearchBatchAsync <T>(this IAzureSearchService searchService, AzureSearchQuery query, string indexName = null, int batchSize = 1000) where T : SearchDocument { var firstPart = await searchService.SearchAsync <T>(query, indexName).ConfigureAwait(false); var results = new List <SearchResult <T> >(); results.AddRange(firstPart.Results); if (firstPart.Count <= batchSize) { return(results); } for (var i = 1; i *batchSize < firstPart.Count; i++) { var queryClone = (AzureSearchQuery)query.Clone(); queryClone.Skip = i * batchSize + query.Skip; queryClone.Top = batchSize; var nextPart = await searchService.SearchAsync <T>(queryClone, indexName) .ConfigureAwait(false); results.AddRange(nextPart.Results); } return(results); }
public SearchController(IAzureSearchService searchService) { _searchService = searchService; }
public IndexGarbageCollector(IAzureSearchService azureSearchService) { _azureSearchService = azureSearchService; }