-
Notifications
You must be signed in to change notification settings - Fork 38.2k
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
Skip runtime hint registration for validation constraint with missing dependencies #33949
Conversation
04886d0
to
8753789
Compare
I still think that we should avoid forwarding bean types of |
Thanks for the reminder, @odrotbohm! While working on this PR, I completely forgot about #33940 (comment), sorry about that. I just pushed a possible solution for beans with @sbrannen mentioned that he plans to discuss this change with the team next week. |
The role infrastructure looks a little bit arbitrary to me. I'd prefer if we use a signal that's more direct to the task at hand. |
Thanks for the suggestion. We can keep things as they are or drop the commit based on what the team decides. |
Hi folks - do you know if there is any workaround for this issue? Currently it blocks an upgrade to SB 3.4.0. Removing the |
As an interim workaround (before 6.2.1 is released), you should hopefully be able to add the dependencies causing the problem. For example, if you're seeing Please let us know if that works for you. |
Team Decision: Merge the PR without the |
The log message for a NoClassDefFoundError is now a DEBUG level message handled like a TypeNotPresentException and similar to the following. DEBUG: Skipping validation constraint hint inference for class org.example.CustomConstraint due to a NoClassDefFoundError for com.example.MissingType See gh-33949
@edeandrea I can confirm that in an empty project with Just bringing the dependency might cause side effects with auto configurations like |
Thank you @scordio - adding |
Prior to this commit, AOT processing for bean validation failed with
NoClassDefFoundError
for constraints with missing dependencies. With this change, the processing no longer fails, and a warning is logged instead.NoClassDefFoundError
#33940Example Log Message