Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

/_stats broken after closing index with alias #15744

Closed
brainsiq opened this issue Jan 4, 2016 · 2 comments
Closed

/_stats broken after closing index with alias #15744

brainsiq opened this issue Jan 4, 2016 · 2 comments
Labels
:Data Management/Indices APIs APIs to create and manage indices and templates :Data Management/Stats Statistics tracking and retrieval APIs

Comments

@brainsiq
Copy link

brainsiq commented Jan 4, 2016

If an aliased index is closed then the _stats endpoint returns an error

curl http://localhost:9200/_stats

{"error":{"root_cause":[{"type":"index_closed_exception","reason":"closed","index":"test_index"}],"type":"index_closed_exception","reason":"closed","index":"test_index"},"status":403}

This does not happen if the alias is removed first. I think that this should not error, it should just exclude the closed index from the stats as normal?

@eskibars eskibars added :Data Management/Stats Statistics tracking and retrieval APIs :Aliases labels Jan 4, 2016
@clintongormley
Copy link
Contributor

Related to #15730 and #14982

@javanna
Copy link
Member

javanna commented Jan 13, 2016

Same as described in #15730 (comment) .

The exception returned by GET _stats has been resolved by #15882, given that not specifying indices is considered a wildcard expressions. GET _stats?expand_wildcards=open,closed does return an exception as the expand_wildcards option is honoured.

If you do specify an alias that points to some closed index, you get back an exception by default: GET alias/_stats but ignore_unavailable allows to control whether closed indices should be ignored or not: GET alias/_stats?ignore_unavailable=true doesn't return exception.

I think we can close this one, the actual bug was same as #13278 which was fixed by #15882 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Data Management/Indices APIs APIs to create and manage indices and templates :Data Management/Stats Statistics tracking and retrieval APIs
Projects
None yet
Development

No branches or pull requests

4 participants