Mapper for [date] conflicts with existing mapper:\n\tCannot update parameter [format] from [yyyyMMdd HH:mm:ss||yyyyMMdd||epoch_millis] to [strict_date_optional_time||epoch_millis]
PUT?http://127.0.0.1:9200/people/man/1 { ????"name":?"wali", ????"country":?"china", ????"age":?29, ????"date":?"1988-03-10" }
報(bào)錯(cuò)
{ ????"error":?{ ????????"root_cause":?[ ????????????{ ????????????????"type":?"illegal_argument_exception", ????????????????"reason":?"Mapper?for?[date]?conflicts?with?existing?mapper:\n\tCannot?update?parameter?[format]?from?[yyyyMMdd?HH:mm:ss||yyyyMMdd||epoch_millis]?to?[strict_date_optional_time||epoch_millis]" ????????????} ????????], ????????"type":?"illegal_argument_exception", ????????"reason":?"Mapper?for?[date]?conflicts?with?existing?mapper:\n\tCannot?update?parameter?[format]?from?[yyyyMMdd?HH:mm:ss||yyyyMMdd||epoch_millis]?to?[strict_date_optional_time||epoch_millis]" ????}, ????"status":?400 }
2021-07-05
format 的格式是:[yyyyMMdd?HH:mm:ss||yyyyMMdd||epoch_millis]
傳入的參數(shù)格式是:
"date"
:?
"1988-03-10"
應(yīng)該是兩者格式不匹配造成報(bào)錯(cuò),要么修改下傳入的參數(shù),要么修改下format的格式