Hi,
I'm using the Elasticsearch Perl module and need guidance on setting up
mappings.
I'm using the bulk() method to index data. Here is an example of the
structure of the data :
$response = $e->bulk(
"index" : "idx-2014.03.10",
"type" : "my_type",
"body" : [
{
"index" : {
"_index" : "idx-2014.03.10",
"_id" : "4410",
"_type" : "my_type"
}
},
{
"something" : "interesting",
"somethingelse" : "also interesting"
},
{
"index" : {
"_index" : "idx-2014.03.10",
"_id" : "4411",
"_type" : "my_type"
}
},
{
"something" : "very interesting",
"somethingelse" : "not interesting"
}
]
);
How do I set up mappings on various fields in the above example for
'something' and 'somethingelse' fields ?
Also, how do I turn off the analyzer for an index (index: not_analyzed)
too ?
I know there are several ways of setting up mappings such as :
- when creating an index
- by using the dedicated update mapping api
- using index templates
Ideally I'd like to use the dedicated update mapping api but am unclear how
to use that through the Perl library interface (eg use transport->perform_request()
?).
Thanks for any guidance and help.
Dom
--
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/f310961e-c389-49ea-82c9-c47d71d32209%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.