File templates functional, but unable to retrieve via API

Hello all,

I have deployed a number of file templates (config/template/*.json)
which are functional - as evidenced by the fact that newly created
indices inherit their settings as expected - but for some reason I
cannot retrieve any information about them via the API.

Excerpt from _cluster/state :
"metadata" : {
"templates" : { },

And when attempting to GET one directly :
$ curl -XGET "localhost:9200/_template/compress"
{}%

For reference :
$ curl -s -XGET "localhost:9200/" | grep number
"number" : "0.19.11",

Again, the templates work - I just don't see them via the API. Is
there some magic that is required here, or is this a potential bug (or
am I just doing something wrong) ? :slight_smile:

Thank you.

--
dan (phrawzty).
mozilla webops; european outpost.

--

Hi Daniel,

The get index template api only returns index templates that are added
via the put index template api.
If you want to view an index template, you need the add an index
template via the api.

Martijn

On 8 November 2012 15:04, Daniel Maher dmaher@mozilla.com wrote:

Hello all,

I have deployed a number of file templates (config/template/*.json) which
are functional - as evidenced by the fact that newly created indices inherit
their settings as expected - but for some reason I cannot retrieve any
information about them via the API.

Excerpt from _cluster/state :
"metadata" : {
"templates" : { },

And when attempting to GET one directly :
$ curl -XGET "localhost:9200/_template/compress"
{}%

For reference :
$ curl -s -XGET "localhost:9200/" | grep number
"number" : "0.19.11",

Again, the templates work - I just don't see them via the API. Is there
some magic that is required here, or is this a potential bug (or am I just
doing something wrong) ? :slight_smile:

Thank you.

--
dan (phrawzty).
mozilla webops; european outpost.

--

--
Met vriendelijke groet,

Martijn van Groningen

--