我正在研究Elastic Search 6.4.2。我想将停用词过滤器应用于索引,以限制停用词查询。我在配置中添加了my_stopwords.txt。我添加了停用词分析器,但是当我签入Kibana时,停用词仍在搜索索引。我该如何限制。
from contextlib import contextmanager
# Method C
@contextmanager
def locked(value):
with value.get_lock():
yield
def my_multiprocessing_worker():
global total_uploaded_files
# do stuff ...
with locked(total_uploaded_files):
# increment shared counter
total_uploaded_files.value += 1