Do not convert @Header name when the name is specified#5841
Merged
Do not convert @Header name when the name is specified#5841
@Header name when the name is specified#5841Conversation
Motivation: We must not convert the header name specified in `@Header` when creating an annotated service. Modifications: - Do not convert the header name specified in `@Header`. Result: - An annotated service that has a `@Header` with the specified name now works correctly.
trustin
reviewed
Jul 29, 2024
| } | ||
|
|
||
| @Post("/headerNameSpecified") | ||
| public String headerNameSpecified(@Header("X-Line-Id") String id) { |
Member
There was a problem hiding this comment.
Can we use more peculiar casing? e.g. X-x-FoO-bAr ?
Contributor
ikhoon
approved these changes
Jul 29, 2024
| } | ||
|
|
||
| /** | ||
| * Returns the value of the {@link Header} annotation which is specified on the {@code element} if |
Contributor
There was a problem hiding this comment.
Shoud we update Javadoc of the method above?
minwoox
added a commit
to minwoox/armeria
that referenced
this pull request
Jul 30, 2024
Motivation: We must not convert the header name specified in `@Header` when creating an annotated service. This is a regression introduced by line#5547, affecting 1.29.0 through 1.29.3. Modifications: - Do not convert the header name specified in `@Header`. Result: - An annotated service that has a `@Header` with the specified name now works correctly.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation:
We must not convert the header name specified in
@Headerwhen creating an annotated service.This is a regression introduced by #5547, affecting 1.29.0 through 1.29.3.
Modifications:
@Header.Result:
@Headerwith the specified name now works correctly.