Template is missing


(Gabriele Angeli-2) #1

i guys, I try to put a new template in ES 1.3.6 but i always obtain the
same result: {"error":"ActionRequestValidationException[Validation Failed:
1: template is missing;]","status":500}
Someone know something about this error? Thanks in advance

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/bf3dee93-c142-4c55-90fb-afd727f8af98%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


(Mark Walkom) #2

Can you put your complete call into a gist or similar for us to check?

On 17 January 2015 at 05:34, Gabriele Angeli g.angeli000@gmail.com wrote:

i guys, I try to put a new template in ES 1.3.6 but i always obtain the
same result: {"error":"ActionRequestValidationException[Validation Failed:
1: template is missing;]","status":500}
Someone know something about this error? Thanks in advance

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/bf3dee93-c142-4c55-90fb-afd727f8af98%40googlegroups.com
https://groups.google.com/d/msgid/elasticsearch/bf3dee93-c142-4c55-90fb-afd727f8af98%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAEYi1X_gNWSq-1XvySwKEDTrjfTkBXw%2BzCqNLtvG8BWQHSQfmw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


(Gabriele Angeli-2) #3

This is my complete query to put a template:

curl -XPUT localhost:9200/_template/mouse -d'
{
"mouse": {
"template": "",
"settings": {
"index.index.refresh_interval": "10s",
"index.routing.allocation.total_shards_per_node": 2
},
"mappings": {
"default": {
"_source": {
"compress": true
},
"dynamic_templates": [
{
"string_template": {
"mapping": {
"index": "not_analyzed",
"type": "string"
},
"match": "
",
"match_mapping_type": "string"
}
}
],
"properties": {
"message": {
"index": "analyzed",
"type": "string"
},
"@timestamp": {
"format": "dateOptionalTime",
"type": "date"
}
},
"_all": {
"enabled": true
}
}
},
"aliases": {}
}
}'

Il giorno sabato 17 gennaio 2015 00:22:21 UTC+1, Mark Walkom ha scritto:

Can you put your complete call into a gist or similar for us to check?

On 17 January 2015 at 05:34, Gabriele Angeli <g.ang...@gmail.com
<javascript:>> wrote:

i guys, I try to put a new template in ES 1.3.6 but i always obtain the
same result: {"error":"ActionRequestValidationException[Validation Failed:
1: template is missing;]","status":500}
Someone know something about this error? Thanks in advance

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearc...@googlegroups.com <javascript:>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/bf3dee93-c142-4c55-90fb-afd727f8af98%40googlegroups.com
https://groups.google.com/d/msgid/elasticsearch/bf3dee93-c142-4c55-90fb-afd727f8af98%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/d3fb0b49-e292-4e72-a4e9-eade6d4a6673%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


(David Grierson) #4

I was burnt by this one as well ... you need to remove the { "mouse" : } section surrounding your template definition.

So it should look something like:

curl -XPUT localhost:9200/_template/mouse -d' { "template": "*", "settings": { "index.index.refresh_interval": "10s", "index.routing.allocation.total_shards_per_node": 2 }, "mappings": { ... etc. ... } }


(Chris) #5

Thanks so much guys! I had the same issue Cx


(system) #6