How to get a list of all indexes in python-elasticsearch

后端 未结 7 1898
北海茫月
北海茫月 2021-02-06 20:32

How would I get a list of the names of an index in Python? Here is what I have so far:

>>> es=e.es
>>> es


        
相关标签:
7条回答
  • 2021-02-06 21:17

    This question comes up when searching for information on retrieving aliases using the python-elasticsearch library. The accepted answer says to use get_aliases but that method has been removed (as of 2017). To get aliases, you can use the following:

     es.indices.get_alias("*")
    
    0 讨论(0)
提交回复
热议问题