mirror of https://github.com/jumpserver/jumpserver
perf: Improve performance by optimizing ES index creation
parent
b3a0d81740
commit
32ec48ac14
|
@ -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:
|
||||
|
|
Loading…
Reference in New Issue