Index Template and object type does not seem to work

I'm trying to create an index template that looks like this:

{
"template": "myindex*",
"order": 0,
"mappings": {
"obj1": {
"properties": {
"obj2": {
"type": "object",
"propterties": {
"id": {
"type": "string",
"index": "not_analyzed"
},
"name": {
"type": "string",
"index": "not_analyzed"
}
}
},
"name": {
"index": "not_analyzed",
"type": "string"
}
}
}
}
}

When creating the index later on, the mapping looks like this:
{
"obj1": {
"properties": {
"obj2": {
"type": "object"
},
"name": {
"type": "string",
"index": "not_analyzed"
}
}
}
}

And when I index a document the mapping of fields "obj2.id" and "obj2.name"
are dynamically created (with type string) but does not become
"not_analyzed" which is what I need them to be.

Any ideas? Is it not possible to use object mappings in index templates?

I'm running ES version 0.19.8.

--
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.
For more options, visit https://groups.google.com/groups/opt_out.

Never mind, the error was caused by a typo - saw it when I read my post
after posting it.

On Thursday, March 28, 2013 12:10:07 PM UTC+1, SomeUser wrote:

I'm trying to create an index template that looks like this:

{
"template": "myindex*",
"order": 0,
"mappings": {
"obj1": {
"properties": {
"obj2": {
"type": "object",
"propterties": {
"id": {
"type": "string",
"index": "not_analyzed"
},
"name": {
"type": "string",
"index": "not_analyzed"
}
}
},
"name": {
"index": "not_analyzed",
"type": "string"
}
}
}
}
}

When creating the index later on, the mapping looks like this:
{
"obj1": {
"properties": {
"obj2": {
"type": "object"
},
"name": {
"type": "string",
"index": "not_analyzed"
}
}
}
}

And when I index a document the mapping of fields "obj2.id" and "obj2.name"
are dynamically created (with type string) but does not become
"not_analyzed" which is what I need them to be.

Any ideas? Is it not possible to use object mappings in index templates?

I'm running ES version 0.19.8.

--
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.
For more options, visit https://groups.google.com/groups/opt_out.