For the future, I would like to do the following :
Index will be daily : index_name_YYYYMMDD
Index will contains N types : index_name_type1, index_name_type2, ...
index_name_typeN
All types will have the same format/mapping.
How can I handle this case with a pre-configured mapping set in the
sub-folder config/mapping ?
I know that I can handle it somehow but putting a default mapping, but will
it work with more than one index case?
Example : I would do a default mapping for all indexes which have a
common prefix (INDEX_A_YYYYMMDD => mapping_A, INDEX_B_YYYYMMDD =>
mapping_B, etc ...)
Right now, I have only one index which does contain 1 type. So I did
create the mapping and place under the config/mapping as explained by the
documentation : Config Mappings | Reference [0.90] | Elastic
.
For the future, I would like to do the following :
Index will be daily : index_name_YYYYMMDD
Index will contains N types : index_name_type1, index_name_type2,
... index_name_typeN
All types will have the same format/mapping.
How can I handle this case with a pre-configured mapping set in the
sub-folder config/mapping ?
I know that I can handle it somehow but putting a default mapping, but
will it work with more than one index case?
Example : I would do a default mapping for all indexes which have a
common prefix (INDEX_A_YYYYMMDD => mapping_A, INDEX_B_YYYYMMDD =>
mapping_B, etc ...)
Thanks for you answer. Following the instructions above, I have created 1
template to handle a daily based index with multi types. I created a json
file which I dropped under config/templates.
file name is tpl-INDEX_NAME.json
content :
On 11 May 2015 at 06:49, Mohamed TEYEB <mohame...@gmail.com <javascript:>>
wrote:
Hi,
Right now, I have only one index which does contain 1 type. So I did
create the mapping and place under the config/mapping as explained by the
documentation : Config Mappings | Reference [0.90] | Elastic
.
For the future, I would like to do the following :
Index will be daily : index_name_YYYYMMDD
Index will contains N types : index_name_type1, index_name_type2,
... index_name_typeN
All types will have the same format/mapping.
How can I handle this case with a pre-configured mapping set in the
sub-folder config/mapping ?
I know that I can handle it somehow but putting a default mapping, but
will it work with more than one index case?
Example : I would do a default mapping for all indexes which have a
common prefix (INDEX_A_YYYYMMDD => mapping_A, INDEX_B_YYYYMMDD =>
mapping_B, etc ...)
That just means that the data in a document/event that was sent to ES did
not match the mapping that you provided. Buy default, ES will dynamically
map any new fields and then add them to the existing mapping.
To check what that difference is, just grab the mapping from ES and then
compare to the one in the file.
Thanks for you answer. Following the instructions above, I have created 1
template to handle a daily based index with multi types. I created a json
file which I dropped under config/templates.
file name is tpl-INDEX_NAME.json
content :
Right now, I have only one index which does contain 1 type. So I did
create the mapping and place under the config/mapping as explained by the
documentation : Config Mappings | Reference [0.90] | Elastic
.
For the future, I would like to do the following :
Index will be daily : index_name_YYYYMMDD
Index will contains N types : index_name_type1, index_name_type2,
... index_name_typeN
All types will have the same format/mapping.
How can I handle this case with a pre-configured mapping set in the
sub-folder config/mapping ?
I know that I can handle it somehow but putting a default mapping, but
will it work with more than one index case?
Example : I would do a default mapping for all indexes which have a
common prefix (INDEX_A_YYYYMMDD => mapping_A, INDEX_B_YYYYMMDD =>
mapping_B, etc ...)
I checked and the only difference is the name of the type ... but also a
type called 'default' get created and nothing common with the mapping
that I have set-up in the file.
I have also another question about my use case, my types will be handling
the language of the documents basically and I would like to know if it's
possible to fix a different analyzer and warmers for types linked to the
same index and not the index itself ? (the language code will be the last
2/3 chars of each type and also a field of each document)
BR.
On Thursday, 14 May 2015 23:49:16 UTC+2, Mark Walkom wrote:
That just means that the data in a document/event that was sent to ES did
not match the mapping that you provided. Buy default, ES will dynamically
map any new fields and then add them to the existing mapping.
To check what that difference is, just grab the mapping from ES and then
compare to the one in the file.
On 15 May 2015 at 03:02, Mohamed T. <mohame...@gmail.com <javascript:>>
wrote:
Hi,
Thanks for you answer. Following the instructions above, I have created 1
template to handle a daily based index with multi types. I created a json
file which I dropped under config/templates.
file name is tpl-INDEX_NAME.json
content :
Right now, I have only one index which does contain 1 type. So I did
create the mapping and place under the config/mapping as explained by the
documentation : Config Mappings | Reference [0.90] | Elastic
.
For the future, I would like to do the following :
Index will be daily : index_name_YYYYMMDD
Index will contains N types : index_name_type1, index_name_type2,
... index_name_typeN
All types will have the same format/mapping.
How can I handle this case with a pre-configured mapping set in the
sub-folder config/mapping ?
I know that I can handle it somehow but putting a default mapping, but
will it work with more than one index case?
Example : I would do a default mapping for all indexes which have a
common prefix (INDEX_A_YYYYMMDD => mapping_A, INDEX_B_YYYYMMDD =>
mapping_B, etc ...)
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.