def reset_store(self):
"""
Opens a database for points
"""
logging.info('Resetting Elasticsearch database')
self.db = Elasticsearch(
[self.settings.get('host', 'localhost:9200')],
)
try:
self.db.indices.create(index='mcp-watch', ignore=400) # may exist
except ConnectionError as feedback:
logging.error('- unable to connect')
raise
return self.db
评论列表
文章目录