mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-09-01 15:37:19 +00:00
perf: Improve performance by optimizing ES index creation
This commit is contained in:
@@ -190,7 +190,8 @@ class ES(object):
|
||||
mappings['aliases'] = {
|
||||
self.query_index: {}
|
||||
}
|
||||
|
||||
if self.es.indices.exists(index=self.index):
|
||||
return
|
||||
try:
|
||||
self.es.indices.create(index=self.index, body=mappings)
|
||||
except (RequestError, BadRequestError) as e:
|
||||
|
Reference in New Issue
Block a user