Reputation: 2544
In SolrCloud Collections API (https://cwiki.apache.org/confluence/display/solr/Collections+API), we can list collections using action:
/admin/collections?action=LIST
However, aliases are not included in this list. There is also no corresponding command for aliases (we can only CREATEALIAS
or DELETEALIAS
). How to list aliases?
Upvotes: 6
Views: 5874
Reputation: 13208
For Solr 6.6+, you could use:
/solr/admin/collections?action=LISTALIASES
See https://solr.apache.org/guide/6_6/collections-api.html#CollectionsAPI-listaliases
Upvotes: 1
Reputation: 226
The aliases list can be fetched in json format using the following command.
[solr_server_hostname]:8983/solr/zookeeper?detail=true&path=/aliases.json
The "data" field in this JSON holds the list of collections object.
Upvotes: 4
Reputation: 2544
This feature seems to be not implemented yet: https://issues.apache.org/jira/browse/SOLR-4968
However, you can use this command:
/admin/collections?action=CLUSTERSTATUS
Each collection will be listed together with the aliases it is covered by. Also in the bottom of the XML there is a separate node, summarising all aliases and covered collections.
Upvotes: 8