Skip to content

Conversation

@TimHess
Copy link
Member

@TimHess TimHess commented May 29, 2025

Description

To answer the original question: when using Spring Boot as the spec for these interactions, HTTP 503 can be the "correct" response.

This PR:

  • Adds testing of various potential cloud controller responses
  • Allows usage of 401 response code (all 4xx errors besides 403) | relevant Spring code
  • Allows usage of 500 response code, with error message in response | relevant Spring code

Resolves #1446

Quality checklist

  • Your code complies with our Coding Style.
  • You've updated unit and/or integration tests for your change, where applicable.
  • You've updated documentation for your change, where applicable.
    If your change affects other repositories, such as Documentation, Samples and/or MainSite, add linked PRs here.
  • There's an open issue for the PR that you are making. If you'd like to propose a new feature or change, please open an issue to discuss the change or find an existing issue.
  • You've added required license files and/or file headers (explaining where the code came from with proper attribution), where code is copied from StackOverflow, a blog, or OSS.

@TimHess TimHess marked this pull request as ready for review June 2, 2025 21:34
@TimHess TimHess requested a review from bart-vmware June 5, 2025 19:41
@TimHess TimHess self-assigned this Jun 5, 2025
@TimHess TimHess added Component/Management Issues related to Steeltoe Management (actuators) ReleaseLine/4.x Identified as a feature/fix for the 4.x release line labels Jun 5, 2025
@TimHess TimHess added this to the 4.0.0-rc1 milestone Jun 5, 2025
@TimHess TimHess requested a review from bart-vmware June 6, 2025 14:49
@TimHess TimHess requested a review from bart-vmware June 11, 2025 15:55
Copy link
Member

@bart-vmware bart-vmware left a comment

Choose a reason for hiding this comment

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

LGTM

TimHess and others added 12 commits June 12, 2025 10:32
- Use Microsoft.Net.Http.Headers.HeaderNames.Authorization
- Move permissions messages to static class
- Rename to ParsePermissionsResponseAsync
- test cleanup
- move integration scenarios to dedicated class
- allow assert on presence of multiple log entries per scenario
- use a mock on RedactsHttpHeaders now that exceptions aren't caught
@bart-vmware bart-vmware merged commit 86ae318 into main Jun 12, 2025
25 checks passed
@bart-vmware bart-vmware deleted the cf_permissions branch June 12, 2025 08:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Component/Management Issues related to Steeltoe Management (actuators) ReleaseLine/4.x Identified as a feature/fix for the 4.x release line

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Is the 503 status code correct when the request to check permissions in CF fails

3 participants