Remove es_urls attribute from ElasticsearchBackend

This gets converted into es_hosts and es_urls isn't used at runtime
pull/1466/merge
Karl Hobley 2015-07-02 17:22:55 +01:00
rodzic 4c24e1a1ec
commit c329f7e6b5
1 zmienionych plików z 2 dodań i 2 usunięć

Wyświetl plik

@ -313,15 +313,15 @@ class ElasticSearch(BaseSearch):
# Get settings
self.es_hosts = params.pop('HOSTS', None)
self.es_urls = params.pop('URLS', ['http://localhost:9200'])
self.es_index = params.pop('INDEX', 'wagtail')
self.es_timeout = params.pop('TIMEOUT', 10)
# If HOSTS is not set, convert URLS setting to HOSTS
es_urls = params.pop('URLS', ['http://localhost:9200'])
if self.es_hosts is None:
self.es_hosts = []
for url in self.es_urls:
for url in es_urls:
parsed_url = urlparse(url)
use_ssl = parsed_url.scheme == 'https'