jprante / elasticsearch-knapsack

Knapsack plugin is an import/export tool for Elasticsearch
Apache License 2.0
472 stars 77 forks source link

#13 Allow override of mapping and settings for each (Index,Type) or for each (Index) or for all index #14

Closed nithril closed 10 years ago

nithril commented 11 years ago

I have a lot of type with the same mapping. I use knapsack to adjust my mapping. It could be usefull to be able to override all mapping with one. I have add "created.clear();" because between each operations added index and type remains stored.

To be honest, I do not have test extensively theses modifications

nithril commented 10 years ago

Any feedback about my pull request?

jprante commented 10 years ago

I think the best method is to use _default_ for the mapping that overrides all mappings, but I have to check how this can be done (the underscore is also a delimiter in the parameter name).

nithril commented 10 years ago

I agree, but in my opinion it is less consistent with the current feature "index_type_mapping.json".

If both can coexist in one request it could be great: a mapping that override all mappings and the ability to override per type.

jprante commented 10 years ago

With the map parameter, it is possible to rename index and type in many variants. How to coerce many type mappings into one is still subject of investigation.