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

rgw/admin: Add ErrNoSuchSubUser #998

Merged
merged 1 commit into from
Jun 13, 2024
Merged

rgw/admin: Add ErrNoSuchSubUser #998

merged 1 commit into from
Jun 13, 2024

Conversation

sj14
Copy link
Contributor

@sj14 sj14 commented Jun 13, 2024

There was no Error for comparing the NoSuchSubUser code.

Example error:

error(github.com/ceph/go-ceph/rgw/admin.statusError) {Code: "NoSuchSubUser", RequestID: "tx0000074e0db2ad9281b8f-00666abc30-10b8-dev1", HostID: "10b8-dev1-dev"}

Reference:

https://github.com/ceph/ceph/blob/8a2a786e62ba1577dde990fef49d18f75efdd023/src/rgw/rgw_common.cc#L106C1-L106C52

Checklist

  • Added tests for features and functional changes
  • Public functions and types are documented
  • Standard formatting is applied to Go code
  • Is this a new API? Added a new file that begins with //go:build ceph_preview
  • Ran make api-update to record new APIs

New or infrequent contributors may want to review the go-ceph Developer's Guide including the section on how we track API Status and the API Stability Plan.

The go-ceph project uses mergify. View the mergify command guide for information on how to interact with mergify. Add a comment with @Mergifyio rebase to rebase your PR when github indicates that the PR is out of date with the base branch.

@sj14 sj14 marked this pull request as ready for review June 13, 2024 09:58
Copy link
Collaborator

@anoopcs9 anoopcs9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please add a related test? You may just expand TestHandleStatusError to consider the error(NoSuchSubUser) which is being added.

Signed-off-by: Simon Jürgensmeyer <simon.juergensmeyer@hetzner-cloud.de>
@sj14
Copy link
Contributor Author

sj14 commented Jun 13, 2024

Added. Unfortunately, I can't test it even though ceph-client is installed via homebrew:

# github.com/ceph/go-ceph/rados
some/path/go-ceph/rados/alloc_hint_flags.go:4:11: fatal error: 'rados/librados.h' file not found
 #include <rados/librados.h>
          ^~~~~~~~~~~~~~~~~~
1 error generated.
FAIL	github.com/ceph/go-ceph/rgw/admin [build failed]

Copy link
Collaborator

@anoopcs9 anoopcs9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added. Unfortunately, I can't test it even though ceph-client is installed via homebrew:

No worries, our CI has it covered.

=== RUN TestHandleStatusError
--- PASS: TestHandleStatusError (0.00s)

rgw/admin/errors_test.go Show resolved Hide resolved
Copy link
Collaborator

@anoopcs9 anoopcs9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, thanks.

@phlogistonjohn phlogistonjohn added the no-API This PR does not include any changes to the public API of a go-ceph package label Jun 13, 2024
@mergify mergify bot merged commit 9604e19 into ceph:master Jun 13, 2024
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-API This PR does not include any changes to the public API of a go-ceph package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants