# Elasticsearch:es-hadoop

**URL:** <https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667>\
**Category:** Elasticsearch\
**Created:** [June 23, 2017, 4:07pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667 "2017-06-23T16:07:41Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![likhita](https://avatars.discourse-cdn.com/v4/letter/l/4da419/32.png) [@likhita](https://discuss.elastic.co/u/likhita)\
**Post date:** [June 23, 2017, 4:07pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667/1 "2017-06-23T16:07:42Z")

</div>

Hello,

I'm working on the percolator queries. When I run the following command, it gives me an error:

```auto
curl -XPUT 'http://localhost:9200/es-storm/.percolator/1' -d '{
     "query": {
                  "match": {
                     "tweet": "bigdata analytics hadoop spark elasticsearch nosql graphdb cassandra mongo mongodb datascience pig hive solar cloudera hortonworks iot"
                  }
               }
}';

```

Error:

```auto
{"error":"PercolatorException[[es-storm] failed to parse query [1]]; nested: QueryParsingException[[es-storm] Strict field resolution and no field mapping can be found for the field with name [tweet]]; ","status":500}

```

Can someone help me with this please.

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [June 23, 2017, 4:20pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667/2 "2017-06-23T16:20:29Z")

</div>

You did not define a mapping for tweet field ?

---

<div class="post-metadata">

**Author:** ![likhita](https://avatars.discourse-cdn.com/v4/letter/l/4da419/32.png) [@likhita](https://discuss.elastic.co/u/likhita)\
**Post date:** [June 23, 2017, 4:40pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667/3 "2017-06-23T16:40:18Z")

</div>

I've defined the mappings field and now it gives me the following error:

```auto
curl -XPUT 'http://localhost:9200/es-storm/.percolator/1' -d '
 {
 "mappings": {
 "query": {
                   "match": {
                      "tweet": "bigdata analytics hadoop spark elasticsearch nosql graphdb cassandra mongo mongodb datascience pig hive solar cloudera hortonworks iot"
                   }
                }
 }
 }';

```

Error:

```auto
{"error":"PercolatorException[[es-storm] failed to parse query [1]]; nested: NullPointerException; ","status":500}

```

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [June 23, 2017, 5:00pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667/4 "2017-06-23T17:00:20Z")

</div>

Restart from scratch.  
Provide a full example.

.percolator is not used anymore in 5.x BTW. Which version have you?

---

<div class="post-metadata">

**Author:** ![likhita](https://avatars.discourse-cdn.com/v4/letter/l/4da419/32.png) [@likhita](https://discuss.elastic.co/u/likhita)\
**Post date:** [June 23, 2017, 6:38pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667/5 "2017-06-23T18:38:33Z")

</div>

I am trying to create percolator queries in the Elasticsearch index. So first I create the index using the below queries:

```auto
curl -XPUT 'http://localhost:9200/es-storm/.percolator/1' -d '{
     "query": {
                  "match": {
                     "tweet": "bigdata analytics hadoop spark elasticsearch nosql graphdb cassandra mongo mongodb datascience pig hive solar cloudera hortonworks iot"
                  }
               }
}';

```

```auto
curl -XPOST 'http://localhost:9200/es-storm/.percolator/1
{
    "query" : {
        "match" : {
            "tweet" : "bigdata analytics hadoop spark elasticsearch eshadoop nosql mongo mongodb cassandra hbase titan orientdb neo4j storm pig hive cloudera hortonworks"
        }
    }
}'

```

Now I want to execute the percolate query:

```auto
curl -XGET 'http://localhost:9200/es-storm/storm-tweets/_percolate' –d '{
    "doc" : {
        "tweet" : "I can't believe that I can now analyse trends from the hadoop data in a snap using Elasticsearch-Hadoop."
    }
}'

```

Which doesn't happen, as it gives me the errors that I mentioned in the previous posts.  
Can you please tell me which version you want to know?

---

<div class="post-metadata">

**Author:** ![likhita](https://avatars.discourse-cdn.com/v4/letter/l/4da419/32.png) [@likhita](https://discuss.elastic.co/u/likhita)\
**Post date:** [June 23, 2017, 7:52pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667/6 "2017-06-23T19:52:56Z")

</div>

I am able to run the first and second queries, but when I try to run the third (percolate) query it doesn't run. It still waits for something to be done:

```auto
[eshadoop@localhost ~]$ curl -XGET http://localhost:9200/es-storm/storm-tweets/_percolate -d '
{
 "doc" : {
    "tweet" : "I can't believe that I can now analyze trends from hadoop data in a snap using Elasticsearch-Hadoop."
}
}';
> 
> 
> 

```

I don't know where I went wrong. Can you please look into it. Help would be greatly appreciated. Thanks in advance.

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [June 23, 2017, 8:17pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667/7 "2017-06-23T20:17:11Z")

</div>

I meant elasticsearch version. What is it?

---

<div class="post-metadata">

**Author:** ![likhita](https://avatars.discourse-cdn.com/v4/letter/l/4da419/32.png) [@likhita](https://discuss.elastic.co/u/likhita)\
**Post date:** [June 26, 2017, 2:37pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667/8 "2017-06-26T14:37:22Z")

</div>

version - 1.7.1

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [June 26, 2017, 2:56pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667/9 "2017-06-26T14:56:04Z")

</div>

So many changed from that version. It has been completely rewritten since then.  
1.x is not supported anymore. So start a 5.4.2 version and play with this version instead.

---

<div class="post-metadata">

**Author:** ![likhita](https://avatars.discourse-cdn.com/v4/letter/l/4da419/32.png) [@likhita](https://discuss.elastic.co/u/likhita)\
**Post date:** [June 26, 2017, 3:00pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667/10 "2017-06-26T15:00:00Z")

</div>

ohh okay... I will try it. Thank you.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 24, 2017, 3:00pm UTC](https://discuss.elastic.co/t/elasticsearch-es-hadoop/90667/11 "2017-07-24T15:00:17Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
