Elasticsarch issues after migrating to AWS ES

I am trying to use AWS Elasticsearch without no luck yet even i configured it right and it created the index required
here is an issue when I try to “yarn dump”
starting dump

throw new Error(‘failed to parse json (message: "’ + e.message + '") - source: ’ + JSON.stringify(str))

Error: failed to parse json (message: “Unexpected token < in JSON at position 0”) - source: “\r\n400 The plain HTTP request was sent to HTTPS port\r\n\r\n

400 Bad Request

\r\nThe plain HTTP request was sent to HTTPS port\r\n\r\n\r\n”
at Object.parse (/home/pwa/vsf/vue-storefront-api/node_modules/elasticdump/lib/jsonparser.js:28:11)
at Request. (/home/pwa/vsf/vue-storefront-api/node_modules/elasticdump/lib/transports/elasticsearch.js:119:29)
at Request._callback (/home/pwa/vsf/vue-storefront-api/node_modules/lodash/lodash.js:10050:25)
at Request.requestRetryReply [as reply] (/home/pwa/vsf/vue-storefront-api/node_modules/requestretry/index.js:105:19)
at Request. (/home/pwa/vsf/vue-storefront-api/node_modules/requestretry/index.js:146:10)
at Request.self.callback (/home/pwa/vsf/vue-storefront-api/node_modules/request/request.js:185:22)
at Request.emit (node:events:379:20)
at Request.EventEmitter.emit (node:domain:470:12)
at Request. (/home/pwa/vsf/vue-storefront-api/node_modules/request/request.js:1161:10)
at Request.emit (node:events:379:20)

please HELP

Hello @neoxero

  1. Unexpected token < in JSON at position 0 comes from the fact your endpoint has returned HTML instead of JSON. So you need to fix THAT

  2. the fact your setup uses HTTP and port 443 means there has been something wrong done when you have set up your instance. Please have a look at
    and make sure your whole traffic is done through HTTPS

I added “https://” to the host and now it is giving me this error
Wed, 17 Mar 2021 22:48:25 GMT | Error Emitted => getaddrinfo EAI_AGAIN https

and here a part of my VSF-api config

“elasticsearch”: {
“host”: “https://user:password@search-xxxxx.me-south-1.es.amazonaws.com”,
“index”: “vue_storefront_catalog”,
“port”: 443,
“protocol”: “https”,
“requestTimeout”: 5000,
“min_score”: 0.01,
“indices”: [
“indexTypes”: [
“apiVersion”: “7.9”,

Please check this error and tell me what do you think the problem is
Error during render : /
Error: Error: {“root_cause”:[{“type”:“illegal_argument_exception”,“reason”:“request [/paris_catalog_ar/product/_search] contains unrecognized parameters: [_source_exclude] -> did you mean any of [_source_excludes, _source_includes]?, [request] -> did you mean [request_cache]?, [request_format] -> did you mean [request_cache]?, [response_format]”}],“type”:“illegal_argument_exception”,“reason”:“request [/paris_catalog_ar/product/_search] contains unrecognized parameters: [_source_exclude] -> did you mean any of [_source_excludes, _source_includes]?, [request] -> did you mean [request_cache]?, [request_format] -> did you mean [request_cache]?, [response_format]”}
at SearchAdapter.exports.modules…/core/lib/search/adapter/api-search-query/searchAdapter.ts.SearchAdapter.handleResult (core/lib/search/adapter/api-search-query/searchAdapter.ts:125:14)
at Object.resultProcessor (core/lib/search/adapter/api-search-query/searchAdapter.ts:155:22)
at server-bundle.js:4426:92
at processTicksAndRejections (node:internal/process/task_queues:94:5)
at _commonErrorHandler (core/server-entry.ts:18:11)
at server-bundle.js:22030:41
at processTicksAndRejections (node:internal/process/task_queues:94:5)
[module] VS Modules registration finished. { succesfulyRegistered: ‘0 / 0’, registrationOrder: [] }
Calling asyncData for Error page Thu Mar 18 2021 21:35:26 GMT+0000 (Coordinated Universal Time) null
Top-most asyncData executed null
HTML Minifier is enabled
whole request [/error]: 446ms

It clearly means that you configured app for using ES5.6 but you are using ES7. I can see it because there were breaking changes in ES6 for some param names and it throws the error right now.

Please make sure to just set version ES7 everywhere and it should be fine.