Yes, I can put up a fix - looks weird.

Most users have either a constant mapping that can extend dynamically, or
does not change on existing field.

If fields have to change for future documents, you can also change mapping
by using alias technique:

- old index with old fields (no change)

- new index created with changed fields

- assigning an index alias to both indices

- search on index alias

No copy required.

Jörg




On Wed, Oct 22, 2014 at 1:27 PM, <euneve...@gmail.com> wrote:

> Jorg,
>
> Thanks for the quick turnaround on putting in the fix.
>
> What I found when I tested is that it works for test, testcopy
>
> But when I try with myindex, myindexcopy doesn't work
>
> I noticed in the logs when I was trying "myindex" that it was looking for
> an index "test" which was a bit odd
>
> So I copied my "myindex" to an index named literally  "test" and only then
> it worked
> So the only index that can be copied is "test"
> The target index can be anything.
>
> Logs:
>
> [2014-10-22 12:05:07,649][INFO ][KnapsackPushAction       ] start of push:
> {"mode":"push","started":"2014-10-22T11:05:07.648Z","node_name":"Pathway"}
> [2014-10-22 12:05:07,649][INFO ][KnapsackService          ] update cluster
> settings: plugin.knapsack.export.state ->
> [{"mode":"push","started":"2014-10-22T11:05:07.648Z","node_name":"Pathway"}]
> [2014-10-22 12:05:07,650][INFO ][KnapsackPushAction       ]
> map={myindex=myindexcopy}
> [2014-10-22 12:05:07,650][INFO ][KnapsackPushAction       ] getting
> settings for indices [test, myindex]
> [2014-10-22 12:05:07,651][INFO ][KnapsackPushAction       ] found indices:
> [test, myindex]
> [2014-10-22 12:05:07,652][INFO ][KnapsackPushAction       ] getting
> mappings for index test and types []
> [2014-10-22 12:05:07,652][INFO ][KnapsackPushAction       ] found
> mappings: [test]
> [2014-10-22 12:05:07,653][INFO ][KnapsackPushAction       ] adding
> mapping: test
> [2014-10-22 12:05:07,653][INFO ][KnapsackPushAction       ] creating
> index: test
> [2014-10-22 12:05:07,672][INFO ][KnapsackPushAction       ] count=2
> status=OK
>
> I guess you can put in a quick fix?
>
> I would have to ask if anyone is using this?
>
> And what are most people doing? Are there any plans by "ES" to create a
> product or does the snapshot feature suffice for most people?
>
> Again I just would repeat my requirements: I want to change the mapping
> types for an existing index. Therefore I create my new index and copy the
> old index data into the new.
>
> Thanks in advance.
>
> On Monday, October 20, 2014 8:42:48 PM UTC+1, Jörg Prante wrote:
>
>> I admit there is something overcautious in the knapsack release to
>> prevent overwriting existing data. I will add a fix that will allow writing
>> into an empty index.
>>
>> https://github.com/jprante/elasticsearch-knapsack/issues/57
>>
>> Jörg
>>
>> On Mon, Oct 20, 2014 at 6:47 PM, <eune...@gmail.com> wrote:
>>
>>> By the way
>>> Es version 1.3.4
>>> Knapsack version built with 1.3.4
>>>
>>>
>>> Regards.
>>>
>>> --
>>> 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 elasticsearc...@googlegroups.com.
>>> To view this discussion on the web visit https://groups.google.com/d/
>>> msgid/elasticsearch/e69c6778-cbc5-4e56-bf71-9bac56b66942%
>>> 40googlegroups.com.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>  --
> 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+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/elasticsearch/2ff794cd-c1bf-463f-81f1-ce9a20da3b6e%40googlegroups.com
> <https://groups.google.com/d/msgid/elasticsearch/2ff794cd-c1bf-463f-81f1-ce9a20da3b6e%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elasticsearch/CAKdsXoFR_0-%3DOt%3DsY4Y4tt%3D0quh8-%3D7zEBVjAHAKZGppkAuRFA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to