Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
web-et-numerique
web-et-numerique-internet
data.grandlyon.com
web-portal
components
indexers
editorial-content
Commits
ea2fc2af
Commit
ea2fc2af
authored
Feb 01, 2019
by
Alessandro CERIONI
Browse files
Deleting the destination index before reindexation.
parent
f9e596bd
Changes
1
Hide whitespace changes
Inline
Side-by-side
lib/reindexer.py
View file @
ea2fc2af
...
...
@@ -23,11 +23,11 @@ def reindexer(cfg):
# t1 = time.time()
#
try:
#
rep = destination_es.indices.delete(cfg['reindexer']['destination_index'])
#
print(rep)
#
except:
#
pass
try
:
rep
=
destination_es
.
indices
.
delete
(
cfg
[
'reindexer'
][
'destination_index'
])
#
print(rep)
except
:
pass
try
:
rep
=
destination_es
.
indices
.
create
(
cfg
[
'reindexer'
][
'destination_index'
])
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment