Questions tagged [elasticsearch-2.0]

Use this tag for version specific questions about Elasticsearch 2.0 - the distributed, RESTful search and analytics engine. When using this tag also include the more generic [elasticsearch] tag where possible.

Elasticsearch 2.0 takes huge strides forward in terms of speed, security, scalability, and hardware efficiency. It introduces a host of new features, including powerful new aggregations to do more analytics, cluster state diffs to support even larger clusters, compatibility with 2.0 versions of Shield (security), Marvel (monitoring), Watcher (alerts), and more.

345 questions
37
votes
6 answers

User authentication in Elasticsearch query using python

I'm using elastisearch using Python. My code looks somewhat like this:- from elasticsearch import Elasticsearch if __name__ == '__main__': index="IndexPosition" es=Elasticsearch(['https://localhost:8080']) res =…
35
votes
3 answers

Kibana on Docker cannot connect to Elasticsearch

I tried to create Kibana and Elasticsearch and it seems that Kibana is having trouble identifying Elasticsearch. Here are my steps: 1) Create network docker network create mynetwork --driver=bridge 2) Run Elasticsearch Container docker run -d -p…
Gunith D
  • 1,843
  • 1
  • 31
  • 36
31
votes
2 answers

How to check if an index exists in elasticsearch using a python script and perform exception handling over it?

How do I check whether an index exists or not using a python query? I'm passing my index as a variable assigned outside the query as :- i=int(datetime.datetime.now().strftime('%d'))+1 indextring="index" for m in range (i-10,i): d =…
16
votes
2 answers

NoMethodError (undefined method `highlight' for #

I'm going to use elastic search for my ruby on rails project. I get this error when I search some of the word that It's used in my article too much. NoMethodError (undefined method `highlight' for…
Hussein Ojaghi
  • 2,260
  • 3
  • 23
  • 41
16
votes
3 answers

How to bind Elasticsearch 2.0 on both Loopback and Non-Loopback interfaces?

Starting from version 2.0 Elasticsearch binds only on the loopback interface by default (_local_ in terms of configuration). The documentation says that there is a way to switch to another network, for example, _non_loopback_ binds to the first…
Funbit
  • 1,591
  • 2
  • 14
  • 15
14
votes
3 answers

Looking for Elasticsearch updateByQuery syntax example (Node driver)

You have an Elasticsearch index with two docs: [ { "_index": "myIndex", "_type": "myType", "_id": "es1472002807930", "_source": { "animal": "turtle", "color": "green", "weight": 20, } }, { "_index":…
James Jensen
  • 255
  • 1
  • 2
  • 11
14
votes
2 answers

elasticsearch what is the difference between best_field and most_field

I already ready this article https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-multi-match-query.html but couldn't figure it out myself. lets have these two queries: first GET blablabla/_search { "query": { …
michael Salam
  • 333
  • 2
  • 12
9
votes
2 answers

Kibana : Cannot query with regex having space

I have a field as author Jason Pete Jason Paul Mike Yard Jason Voorhies in kibana 4.4 i am querying as author:/Jason.*/ so i get all records for Jason Pete Jason Paul Jason Voorhies fine, now i want to do author:/Jason P.*/ i expect Jason…
AbtPst
  • 7,778
  • 17
  • 91
  • 172
9
votes
0 answers

Elasticsearch optional maven depdendencies

I am using Elasticsearch 2.1. When I start up the system, I get several exceptions about failing to load classes related to scripting. For example, failed to load mustache java.lang.ClassNotFoundException: com.github.mustachejava.Mustache I can…
Mike
  • 1,791
  • 1
  • 17
  • 23
9
votes
1 answer

How to set _id in elasticsearch 2.0

Since the configuration of path on the _id field of a specific mapping is deprecated (as noted in the documentation here), How can I set the _id field for a specific document in elasticsearch 2.0 ? (In my specific use-case, I want to index all…
gillyb
  • 8,760
  • 8
  • 53
  • 80
8
votes
1 answer

Duplicate documents in Elasticsearch index with the same _uid

We've discovered some duplicate documents in one of our Elasticsearch indices and we haven't been able to work out the cause. There are two copies of each of the affected documents, and they have exactly the same _id, _type and _uid fields. A GET…
Suzanne
  • 171
  • 1
  • 6
8
votes
1 answer

ElasticSearch: inner_hits and hightlight_query

Short version: Is it somehow possible to obtain the functionality delivered by highlight_query for the highlighting of inner_hits results? Long version: Please consider the following mapping: { "settings": { "number_of_replicas": 0, …
khituras
  • 1,081
  • 10
  • 25
8
votes
2 answers

Cannot access Elasticsearch 2.0 in Vagrant VM from host OS

I'm trying to get Elasticsearch 2.0 up and running in a Vagrant VM. The method I was using for 1.7 no longer works, so I'm trying to update my method. I can get ES 2.0 installed in the VM, and it seems to work fine from within the VM, but I can't…
Sloan Ahrens
  • 8,588
  • 2
  • 29
  • 31
7
votes
2 answers

How to draw multi-lines from multiple queries in Kibana

I am new to Kibana and need some help. I can draw this line chart for a single query (java): Now I would like to another line for another query (for example python) in the same chart. I am not so sure how to do that. Also "Markdown widget" is the…
kee
  • 10,969
  • 24
  • 107
  • 168
7
votes
1 answer

Boost elastic [MoreLikeThis] search query for begining of array

I have elastic search documents with structure like this: { "name": "item1", "storages": [ {"items": ["a", "b", "c", "d", "e", "f"]}, {"items": ["a 1", "b 2", "c 3", "d 4", "e 5", "f 6"]}] } { "name": "item2", …
Vladimir
  • 2,082
  • 1
  • 13
  • 27
1
2 3
22 23