Questions tagged [elasticsearch-net]

Repository for both Elasticsearch.Net and NEST, the two official elasticsearch .NET clients.

  • low-level client that provides a one-to-one mapping with the Elasticsearch REST API.
  • No dependencies
  • Almost completely generated from the official REST API spec which makes it easy to keep up to date
  • Comes with an integration test suite that can be generated from the YAML test definitions that the Elasticsearch core team uses to test their REST API
  • Has no opinions on how you create or consume requests and responses
  • Load balancing and cluster failover support *All calls have async variants

Home page for both Elasticsearch.Net and NEST, the two official elasticsearch .NET clients, can be found here.

Source code repository is here.

261 questions
1
vote
1 answer

Elasticsearch time series database logging samples and summing between date range

I need to write an app to account for bandwidth that comes from a sensor, it gives details on data flow in a table captured as below: [ElasticsearchType(Name = "trafficSnapshot")] public class TrafficSnapshot { // use epoch_second @…
morleyc
  • 2,169
  • 10
  • 48
  • 108
1
vote
1 answer

Unit testing elasticsearch.net's implicit operator using Moq

I am not sure ElasticSearch's .net low level client is commonly used yet, because NEST seems to be the "go to" approach to implement an Elasticsearch client in .net. Anyway, among many other methods, the main IElasticLowLevelClient interface…
Sbu
  • 910
  • 11
  • 22
1
vote
1 answer

Elasticsearch NEST highlighting the attachment content

In Elasticsearch 5.6.3 I installed ingest-attachment plugin. I am trying to set the term vector property to WithPositionOffsets in attachment's content. Where should I set this property to see highligted result in my search? The Document POCO is…
1
vote
3 answers

Authorization bearer token with NEST elasticsearch and C#

I've got a problem while trying to connect to an elasticsearch API. The API expect an bearer token, but the NEST lybrary only provides a basic authentication and I've got to pass a custom header as well. So, did anybody have to face this problem??…
1
vote
0 answers

How to use active directory authentication with NEST/Elasticsearch.net

I am aware of how to use basic authentication on the connectionsettings using NEST. But if I wanted to use active directory/ldap authentication, how will I make the connection? Is there any sample available? Is it sample as passing id/pwd when we…
askids
  • 1,406
  • 1
  • 15
  • 32
1
vote
1 answer

How does attribute mapping for the NEST Elasticsearch client work for date times

I have a C# object that I am using to index documents to an existing type in Elasticsearch. The object has a DateTime field that I want to configure the mapping using the the NEST clients attribute based mapping. I am looking to configure the…
Adrian Russell
  • 3,995
  • 5
  • 25
  • 26
1
vote
2 answers

Redirect logs to logstash instance instead of ElasticSearch

I have a question : I`m using Elasticsearch.Net nugget with NLogs in order to send logs to my local Elasticsearch instance. Kibana is visualize them as well, so far soo good. Is it possible using the same nugget to forwards logs to Logstash…
NDym
  • 79
  • 12
1
vote
1 answer

How to implement ElasticSearch with asp.net web application?

I have read the documentation of ElasticSearch and I am familiar with its endpoints and how to maintain Clusters,Nodes,Indices,etc. Now I am planning to use it in an Asp.net web api and I am a little bit confused about what is the best way to…
Waddah Rasheed
  • 239
  • 4
  • 13
1
vote
2 answers

ElasticSearch with Nest: Partial search using multiple words using Query<>.Wildcard

I have been pulling my hair out trying to configure and partial search ElasticSearch indexed data using Nest library version 5.3.1 (same version applies to its one of its dependencies; Elasticsearch.Net). As per suggestions found online I used data…
1
vote
2 answers

Build multiple filter in Elasticsearch

Can you suggest how do I build a query based on multiple filter. Currently, I want to implement a search functionality using the following filters: ProductName Countries (array) Cities (array) The requirements is that, when counties or cities has…
klaydze
  • 941
  • 14
  • 36
1
vote
0 answers

Use query_string for full-text search in parent-child tables in ElasticSearch

we have found a strange behavior inside ElasticSearch querying. We have two types which are connected together as parent (applicant) and child (attachment). Mapping for parent table: { "Applicant": { "properties": { "Name":…
1
vote
1 answer

ElasticSearch - search for any nested field that is in range

I have the next filed as part of an elastic element: "PayPlan" : { "ActivePlans" : { "plan1" : { "startsOn" : "1", "endsOn" : "999999" } }, …
Avishay
  • 305
  • 1
  • 11
1
vote
1 answer

How to prevent indexing field?

I want to prevent indexing Id field for search using Nest attributes. [Number(type: NumberType.Long, IncludeInAll = false, Index = false)] public long Id { get; set; }
1
vote
1 answer

Elasticsearch.Net query using NEST and nested objects to retrieve documents

I'm using Elasticsearch.Net and NEST in an applicationand having trouble accessing documents in an Elasticsearh index when searching based on nested object Ids. The data structure is invoice -> lineItems -> rowItems. I want to search based on these…
CorribView
  • 711
  • 1
  • 19
  • 44
1
vote
1 answer

Searching within a text using ngram for the minimum chars of the search pattern and above

I have an index of text in my elastic server. I have implemented an ngram tokenizer like this: "analysis": { "analyzer": { "ngram_analyzer": { "type": "custom", "tokenizer": "ngram_tokenizer" } }, …
IB.
  • 1,019
  • 3
  • 13
  • 21