본문 바로가기
Error

elasticsearch 에러 {"error":"Content-Type header [application/x-www-form-urlencoded] is not supported","status":406}

by reo.l 2021. 6. 8.

elasticsearch 데이터 파일 PUT, POST 시에 발생하는 에러이다. elasticsearch 6.0 v 이후부터는 엄격하게 content-type을 확인한다고 한다. 

 

-H 'Content-Type: application/json'

curl 명령어에 content-type 옵션을 명시해주자

 

 

 

댓글