public UnitOfWork(Nest.IElasticClient client) { _client = client; _logger = Log.Logger.For <UnitOfWork>(); _pendingDocs = new Dictionary <string, Nest.IBulkOperation>(); _versions = new Dictionary <string, long>(); }
public ElasticSearchRepository( Nest.IElasticClient elasticClient, IEventBus eventBus ) { this.elasticClient = elasticClient ?? throw new ArgumentNullException(nameof(elasticClient)); this.eventBus = eventBus ?? throw new ArgumentNullException(nameof(eventBus)); }
private Task CreateReportIndicMapping(Nest.IElasticClient esClient) { return(esClient.MapAsync <Report>(m => m.Properties(pd => pd.Object <JObject>(otd => otd.Name(r => r.CustomData).Dynamic(false)) ) )); }
private Task CreateRankedScoreMapping(Nest.IElasticClient client) { return(client.MapAsync <ScoreRecord>(m => m.DynamicTemplates(templates => templates .DynamicTemplate("dates", t => t .Match("CreatedOn") .Mapping(ma => ma.Date(s => s)) ) .DynamicTemplate("score", t => t.MatchMappingType("string") .Mapping(ma => ma.String(s => s.Index(Nest.FieldIndexOption.NotAnalyzed))) ) ) )); }
public Select(Nest.IElasticClient client) { _client = client; }
public MeetingQueryHandler( Nest.IElasticClient elasticClient ) { this.elasticClient = elasticClient ?? throw new ArgumentNullException(nameof(elasticClient)); }
public Index(Nest.IElasticClient client) { _client = client; }
public OfferQueryHandler(Nest.IElasticClient elasticClient) => this.elasticClient = elasticClient;
public HandleSearchMeetings( Nest.IElasticClient elasticClient ) { this.elasticClient = elasticClient ?? throw new ArgumentNullException(nameof(elasticClient)); }
public OfferEventHandler(Nest.IElasticClient elasticClient) => this.elasticClient = elasticClient;