Skip to content

[Bugfix] Fix unknown parameter source_remote_translog_repository bug#16192

Merged
sachinpkale merged 1 commit intoopensearch-project:mainfrom
sachinpkale:bugfix-16188
Oct 4, 2024
Merged

[Bugfix] Fix unknown parameter source_remote_translog_repository bug#16192
sachinpkale merged 1 commit intoopensearch-project:mainfrom
sachinpkale:bugfix-16188

Conversation

@sachinpkale
Copy link
Copy Markdown
Member

@sachinpkale sachinpkale commented Oct 4, 2024

Description

  • As part of shallow snapshot V2 restore, we introduced source_remote_translog_repository field in the RestoreSnapshotRequest in order to restore snapshot from one cluster to another.
  • But using source_remote_translog_repository fails with unknown parameter error:
% curl -X POST "localhost:9200/_snapshot/backup-snapshot/S_1/_restore?pretty" -H 'Content-Type: application/json' -d'
{
  "indices": "my-index-1",
  "source_remote_store_repository": "backup-segment",
  "source_remote_translog_repository": "backup-translog"
}
'
{
  "error" : {
    "root_cause" : [
      {
        "type" : "illegal_argument_exception",
        "reason" : "Unknown parameter source_remote_translog_repository"
      }
    ],
    "type" : "illegal_argument_exception",
    "reason" : "Unknown parameter source_remote_translog_repository"
  },
  "status" : 400
}
  • This was a miss while constructing RestoreSnapshotRequest that is fixed in this PR.

Related Issues

Check List

  • Functionality includes testing.
  • API changes companion pull request created, if applicable.
  • Public documentation issue/PR created, if applicable.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Signed-off-by: Sachin Kale <sachinpkale@gmail.com>
@sachinpkale sachinpkale changed the title Fix unknown parameter source_remote_translog_repository bug [Bugfix] Fix unknown parameter source_remote_translog_repository bug Oct 4, 2024
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Oct 4, 2024

✅ Gradle check result for 28e4012: SUCCESS

@codecov
Copy link
Copy Markdown

codecov bot commented Oct 4, 2024

Codecov Report

Attention: Patch coverage is 0% with 6 lines in your changes missing coverage. Please review.

Project coverage is 71.95%. Comparing base (aef7eca) to head (28e4012).
Report is 3 commits behind head on main.

Files with missing lines Patch % Lines
...ster/snapshots/restore/RestoreSnapshotRequest.java 0.00% 3 Missing and 1 partial ⚠️
...apshots/restore/RestoreSnapshotRequestBuilder.java 0.00% 2 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main   #16192      +/-   ##
============================================
- Coverage     72.00%   71.95%   -0.06%     
+ Complexity    64640    64590      -50     
============================================
  Files          5296     5296              
  Lines        301746   301752       +6     
  Branches      43586    43588       +2     
============================================
- Hits         217270   217111     -159     
- Misses        66669    66809     +140     
- Partials      17807    17832      +25     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sachinpkale sachinpkale merged commit 421a1cc into opensearch-project:main Oct 4, 2024
@sachinpkale sachinpkale added the backport 2.x Backport to 2.x branch label Oct 4, 2024
opensearch-trigger-bot bot pushed a commit that referenced this pull request Oct 4, 2024
Signed-off-by: Sachin Kale <sachinpkale@gmail.com>
(cherry picked from commit 421a1cc)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
sachinpkale pushed a commit that referenced this pull request Oct 5, 2024
…16197)

(cherry picked from commit 421a1cc)

Signed-off-by: Sachin Kale <sachinpkale@gmail.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>
dk2k pushed a commit to dk2k/OpenSearch that referenced this pull request Oct 16, 2024
dk2k pushed a commit to dk2k/OpenSearch that referenced this pull request Oct 17, 2024
dk2k pushed a commit to dk2k/OpenSearch that referenced this pull request Oct 21, 2024
akolarkunnu pushed a commit to akolarkunnu/OpenSearch that referenced this pull request Jan 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport 2.x Backport to 2.x branch skip-changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants