[GeoNode-users] Elasticsearch - Index not updated properly

Pascal Coulon Pascal.Coulon at scisys.co.uk
Wed Jan 22 05:57:47 PST 2020


We have found some issue with setting up Elasticsearch for geonode, where the elastic search index does not get properly updated. Each time a new is added to the layer catalogue the last entry in the index gets overridden by the newly uploaded datasets.

We have the following configuration:
Elastic search 2.3.1
Geonode 2.10rc4
django-haystack>=2.8.1
elasticsearch>=2.0.0,<3.0.0

HAYSTACK_SEARCH = True
# # Avoid permissions prefiltering
SKIP_PERMS_FILTER = False
# # Update facet counts from Haystack
HAYSTACK_FACET_COUNTS = True
if HAYSTACK_SEARCH:
    if 'haystack' not in INSTALLED_APPS:
        INSTALLED_APPS += ('haystack', )
HAYSTACK_CONNECTIONS = {
    'default': {
        'ENGINE': 'haystack.backends.elasticsearch2_backend.Elasticsearch2SearchEngine',
        'URL':'http://127.0.0.1:9200/',
        'INDEX_NAME': 'haystack',
    },
    'db': {
        'ENGINE': 'haystack.backends.simple_backend.SimpleEngine',
        'EXCLUDED_INDEXES': ['thirdpartyapp.search_indexes.BarIndex'],
    }
}

HAYSTACK_SIGNAL_PROCESSOR = 'haystack.signals.RealtimeSignalProcessor'
HAYSTACK_SEARCH_RESULTS_PER_PAGE = '20'


We have noticed however that removing the following sort out the index and haystack and elastic search start operating as per expected.
  - "/var/venv/geonode/lib/python2.7/site-packages/geonode/groups/search_indexes.py"
  - "/var/venv/geonode/lib/python2.7/site-packages/geonode/groups/search_indexes.pyc"
  - "/var/venv/geonode/lib/python2.7/site-packages/geonode/people/search_indexes.py"
  - "/var/venv/geonode/lib/python2.7/site-packages/geonode/people/search_indexes.pyc"

Does anyone know off any bug or a way to properly configure elastic search?

Regards,

Pascal




SCISYS UK Limited. Registered in England and Wales No. 4373530.
Registered Office: Methuen Park, Chippenham, Wiltshire SN14 0GB, UK.
 
Before printing, please think about the environment.


<p><span style="color:#696969;"><span style="font-size:9px;"><span style="font-family:arial,helvetica,sans-serif;">CONFIDENTIALITY NOTICE: Proprietary/Confidential Information belonging to CGI Inc. and its affiliates may be contained in this message. If you are not a recipient indicated or intended in this message (or responsible for delivery of this message to such person), or you think for any reason that this message may have been addressed to you in error, you may not use or copy or deliver this message to anyone else. In such case, you should destroy this message and are asked to notify the sender by reply e-mail</span></span></span></p>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geonode-users/attachments/20200122/c1ace23b/attachment-0001.html>


More information about the geonode-users mailing list