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

[BUG] Get snapshot API returns incorrect response #6820

Closed
gaobinlong opened this issue Mar 24, 2023 · 0 comments · Fixed by #6839
Closed

[BUG] Get snapshot API returns incorrect response #6820

gaobinlong opened this issue Mar 24, 2023 · 0 comments · Fixed by #6839
Labels
bug Something isn't working distributed framework

Comments

@gaobinlong
Copy link
Collaborator

Describe the bug
When calling Get snapshot API with setting ignore_unavailable parameter to true, if the snapshot does not exist, then this API will return all of the executing snapshots which are in IN_PROGRESS state.

To Reproduce

  1. Create a snapshot, which will take a long time to execute.
  2. Call the Get Snapshot API with an non-existing snapshot and setting ignore_unavailable parameter to true:
    GET _snapshot/test/xx?ignore_unavailable=true
    then you can see that the response contains the snapshot which is executing and in IN_PROGRESS state.

Expected behavior
Return empty response if the snapshot does not exist.

Screenshots
image

Host/Environment (please complete the following information):

  • OS: [Centos]
  • Version [2.4.1]
@gaobinlong gaobinlong added bug Something isn't working untriaged labels Mar 24, 2023
gaobinlong added a commit to gaobinlong/OpenSearch that referenced this issue Mar 27, 2023
…a non-existing snapshot (opensearch-project#6820)

Signed-off-by: Gao Binlong <gbinlong@amazon.com>
dblock pushed a commit that referenced this issue Apr 6, 2023
…vailable=true (#6839)

* Fix bug for Get Snapshot API to return correct response when getting a non-existing snapshot (#6820)

Signed-off-by: Gao Binlong <gbinlong@amazon.com>

* modify change log

Signed-off-by: Gao Binlong <gbinlong@amazon.com>

* Modify changelog

Signed-off-by: Gao Binlong <gbinlong@amazon.com>

---------

Signed-off-by: Gao Binlong <gbinlong@amazon.com>
opensearch-trigger-bot bot pushed a commit that referenced this issue Apr 6, 2023
…vailable=true (#6839)

* Fix bug for Get Snapshot API to return correct response when getting a non-existing snapshot (#6820)

Signed-off-by: Gao Binlong <gbinlong@amazon.com>

* modify change log

Signed-off-by: Gao Binlong <gbinlong@amazon.com>

* Modify changelog

Signed-off-by: Gao Binlong <gbinlong@amazon.com>

---------

Signed-off-by: Gao Binlong <gbinlong@amazon.com>
(cherry picked from commit 8b34e5f)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
dblock pushed a commit that referenced this issue Apr 6, 2023
…vailable=true (#6839) (#7029)

* Fix bug for Get Snapshot API to return correct response when getting a non-existing snapshot (#6820)



* modify change log



* Modify changelog



---------


(cherry picked from commit 8b34e5f)

Signed-off-by: Gao Binlong <gbinlong@amazon.com>
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working distributed framework
Projects
None yet
3 participants