-
Notifications
You must be signed in to change notification settings - Fork 25.6k
Description
Elasticsearch version (bin/elasticsearch --version):
Version: 6.4.2, Build: default/tar/04711c2/2018-09-26T13:34:09.098244Z, JVM: 10.0.2
Plugins installed: []
JVM version (java -version):
java version "10.0.2" 2018-07-17
Java(TM) SE Runtime Environment 18.3 (build 10.0.2+13)
Java HotSpot(TM) 64-Bit Server VM 18.3 (build 10.0.2+13, mixed mode)
OS version (uname -a if on a Unix-like system):
Darwin C02WJ1HKG8WL 17.7.0 Darwin Kernel Version 17.7.0: Thu Jun 21 22:53:14 PDT 2018; root:xnu-4570.71.2~1/RELEASE_X86_64 x86_64
Description of the problem including expected versus actual behavior:
The document says
index and type in source can both be lists, allowing you to copy from lots of sources in one request.
However I got
Rejecting mapping update to [all_together] as the final mapping would have more than 1 type: [post, doc]
Steps to reproduce:
Please include a minimal but complete recreation of the problem, including
(e.g.) index creation, mappings, settings, query etc. The easier you make for
us to reproduce it, the more likely that somebody will take the time to look at it.
- Create index
twitterwith typedoc, and indexblogwith typepost:
curl -X DELETE "localhost:9200/twitter?pretty"
curl -X DELETE "localhost:9200/blog?pretty"
curl -X POST "localhost:9200/_bulk?pretty" -H 'Content-Type: application/json' -d'
{ "index" : { "_index" : "twitter", "_type" : "doc", "_id" : "1" }}
{ "user" : "kimchi" }
{ "index" : { "_index" : "blog", "_type" : "post", "_id" : "2" }}
{ "title" : "hello world!" }
- Reindex:
curl -X DELETE "localhost:9200/all_together?pretty"
curl -X POST "localhost:9200/_reindex?pretty" -H 'Content-Type: application/json' -d'
{
"source": {
"index": ["blog","twitter"],
"type": ["post","doc"]
},
"dest": {
"index": "all_together"
}
}
'
Provide logs (if relevant):
{
"took" : 865,
"timed_out" : false,
"total" : 2,
"updated" : 0,
"created" : 1,
"deleted" : 0,
"batches" : 1,
"version_conflicts" : 0,
"noops" : 0,
"retries" : {
"bulk" : 0,
"search" : 0
},
"throttled_millis" : 0,
"requests_per_second" : -1.0,
"throttled_until_millis" : 0,
"failures" : [
{
"index" : "all_together",
"type" : "doc",
"id" : "1",
"cause" : {
"type" : "illegal_argument_exception",
"reason" : "Rejecting mapping update to [all_together] as the final mapping would have more than 1 type: [post, doc]"
},
"status" : 400
}
]
}