Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

class level support for @JsonView in JsonViewResponseBodyAdvice #35350

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

Open
asifebrahim wants to merge 5 commits into spring-projects:main
base: main
Choose a base branch
Loading
from asifebrahim:main

Conversation

Copy link

@asifebrahim asifebrahim commented Aug 19, 2025
edited
Loading

Made the necessary changes with a test file

Closes 35343

Signed-off-by: Asif Ebrahim asifebrahim13@gmail.com

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged or decided on label Aug 19, 2025
@bclozel bclozel added status: invalid An issue that we don't feel is valid and removed status: waiting-for-triage An issue we've not yet triaged or decided on labels Aug 19, 2025
Copy link
Contributor

Hey @asifebrahim, I am not sure to understand why you closed this PR which seems to fix #35343 before we had a chance to review it. Could you explain?

Copy link
Author

i thought someone else was assigned to it so that's why..I'll reopen

return super.supports(returnType, converterType) && returnType.hasMethodAnnotation(JsonView.class);
return super.supports(returnType, converterType) &&
(returnType.hasMethodAnnotation(JsonView.class) ||
returnType.getDeclaringClass().isAnnotationPresent(JsonView.class));
Copy link
Contributor

Choose a reason for hiding this comment

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

Should @JsonView on super type be considered?

@sdeleuze sdeleuze added in: web Issues in web modules (web, webmvc, webflux, websocket) type: enhancement A general enhancement and removed status: invalid An issue that we don't feel is valid labels Aug 21, 2025
@sdeleuze sdeleuze self-assigned this Aug 21, 2025
@sdeleuze sdeleuze added this to the 7.0.0-M9 milestone Aug 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers
1 more reviewer

@quaff quaff quaff left review comments

Reviewers whose approvals may not affect merge requirements
Labels
in: web Issues in web modules (web, webmvc, webflux, websocket) type: enhancement A general enhancement
Projects
None yet
Milestone
7.0.0-M9
Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /