django-oscar / django-oscar-elasticsearch

Search app for oscar using elasticsearch
BSD 3-Clause "New" or "Revised" License
20 stars 18 forks source link

Invalid index name #30

Open gabriel-f-santos opened 1 year ago

gabriel-f-santos commented 1 year ago

Hello, i am facing this issue: elasticsearch.exceptions.RequestError: RequestError(400, 'invalid_index_name_exception', "Invalid index name [__catalogueproduct], must not start with ''.") There is something wrong? Thanks!

specialunderwear commented 1 year ago

Hi, Ithink you've incomplete configuration, did you include the "INDEX" name in your WAGTAILSEARCH_BACKENDS settings:

WAGTAILSEARCH_BACKENDS = {
    "default": {
        "BACKEND": "oscar_elasticsearch.search.backend",
        "URLS": ["http://127.0.0.1:9200"],
        "INDEX": "my-index-name",
        "TIMEOUT": 120,
        "OPTIONS": {},
        "INDEX_SETTINGS": {},
        "ATOMIC_REBUILD": True,
        "AUTO_UPDATE": True,
    }
}