denshoproject / ddr-public

Web UI for publishing DDR collections.
Other
1 stars 1 forks source link

Separate hosts for `namesdb` indices not working #204

Open gjost opened 1 year ago

gjost commented 1 year ago

When setting up the develop site I wanted to point docstore_hosts (for ddrpublic.ui) at the black ES cluster but have namesdb_hosts point at the orange cluster. This does not work.

elastictools.docstore.Docstore.__init__ takes a hosts arg and a settings arg. The idea is that the main ddrpublic.ui app would use settings.DOCSTORE_HOSTS while ddrpublic.namesdb could use settings.NAMESDB_DOCSTORE_HOSTS.

The problem is that docstore.es is set in elastictools.docstore.Docstore.get_elasticsearch, which uses settings.DOCSTORE_HOSTS to set the docstore.conn attribute.