Skip to content

Increase Max Http Results Type Args#66092

Open
TheTedder wants to merge 3 commits intodotnet:mainfrom
TheTedder:bump-max-results-args
Open

Increase Max Http Results Type Args#66092
TheTedder wants to merge 3 commits intodotnet:mainfrom
TheTedder:bump-max-results-args

Conversation

@TheTedder
Copy link
Copy Markdown

@TheTedder TheTedder commented Apr 1, 2026

Increase Max Http Results Type Args

  • You've read the Contributor Guide and Code of Conduct.
  • You've included unit or integration tests for your change, where applicable.
  • You've included inline docs for your change, where applicable.
  • 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.

Six isn't enough type args for HTTP endpoints that return many different statuses.

Description

This PR increases the maximum number of type args for the generated Results classes to 8. Imagine you have an HTTP POST endpoint /api/blogs/{blogId}/posts that accepts a blog post JSON response body like so:

{
    "url": "look-what-i-just-knitted",
    "content": "it's a scarf!",
    "dateComposed": "2026-03-29",
    "tags": ["knitting", "updates"]
}

This endpoint needs to support the following statuses:

  • 201 Created.
  • 400 Bad Request — malformed JSON.
  • 401 Unauthorized — not signed in.
  • 403 Forbidden — this is not your blog.
  • 404 Not Found — blog does not exist.
  • 409 Conflict — the friendly URL for your post is already in use.
  • 422 Unprocessable Content — your blog post is syntactically valid but semantically incorrect (date string not valid).

This is a made-up example but a project I'm working on has an endpoint with pretty much this exact setup.

@github-actions github-actions bot added the area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions label Apr 1, 2026
@dotnet-policy-service dotnet-policy-service bot added the community-contribution Indicates that the PR has been added by a community member label Apr 1, 2026
@dotnet-policy-service
Copy link
Copy Markdown
Contributor

Thanks for your PR, @@TheTedder. Someone from the team will get assigned to your PR shortly and we'll get it reviewed.

@TheTedder
Copy link
Copy Markdown
Author

@dotnet-policy-service agree

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions community-contribution Indicates that the PR has been added by a community member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants