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

Minimal content negotiation #1445

Open
wants to merge 2 commits into
base: remove_negotiation
Choose a base branch
from

Conversation

bart-vmware
Copy link
Member

@bart-vmware bart-vmware commented Jan 17, 2025

Description

This PR re-adds content negotiation in a minimal (hard-coded) way. Every actuator uses the same, single media type, which is not extensible. An error is returned when an incompatible Content-Type or Accept header is used.

My concern is that adding content negotiation support after the release of Steeltoe v4 will be a breaking change. This PR ensures that incompatible Content-Type and Accept headers are blocked. This enables Steeltoe to support additional content types in the future and introduce interfaces and/or configuration for third-party actuators to participate in the process, without suddenly starting to fail on requests that used to succeed.

I haven't done any testing with Cloud Foundry, Prometheus or Spring Boot Admin yet. We should verify they are compatible with the changes in this PR before merging it.

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.

@bart-vmware bart-vmware mentioned this pull request Jan 17, 2025
7 tasks
@bart-vmware bart-vmware marked this pull request as ready for review January 17, 2025 15:32
@bart-vmware bart-vmware requested a review from TimHess January 17, 2025 15:32
@bart-vmware bart-vmware added Component/Management Issues related to Steeltoe Management (actuators) ReleaseLine/4.x Identified as a feature/fix for the 4.x release line labels Jan 21, 2025
@bart-vmware bart-vmware added this to the 4.0.0-m1 milestone Jan 21, 2025
@TimHess TimHess force-pushed the remove_negotiation branch 2 times, most recently from 50fdd11 to 47d8e71 Compare January 22, 2025 01:13
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.

2 participants