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

HV-2031 Make PredefinedScopeHibernateValidatorFactory aware of constraint mappings defined purely in XML #1429

Conversation

marko-bekhta
Copy link
Member

https://hibernate.atlassian.net/browse/HV-2031

we have to:

  • add the beans that are defined only in the XML (that's where beanClassesToInitialize.addAll( xmlMetaDataProvider.configuredBeanClasses() ) helps)
  • make sure that the constraint helper has all the constraints we need. Initially it'll have the built-in ones for the ones requested by the config. But if the XML is trying to apply any other constraint, we will be in trouble, as the helper will not have the info. So to make it work the predefined factory is using a "dynamic" version of the helper that goes back to looking up the built-in constraints.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on licensing, please check here.


@marko-bekhta marko-bekhta force-pushed the feat/HV-2031-Make-PredefinedScopeHibernateValidatorFactory-aware-of-constraint-mappings-defined-purely-in-XML branch 3 times, most recently from c36405b to 59e38af Compare September 3, 2024 11:11
so that we can get the "old-default" behavior by-default and enable the additional collection of information from the XML metadata
@marko-bekhta marko-bekhta force-pushed the feat/HV-2031-Make-PredefinedScopeHibernateValidatorFactory-aware-of-constraint-mappings-defined-purely-in-XML branch from 59e38af to 95adbe6 Compare September 3, 2024 14:42
@marko-bekhta marko-bekhta merged commit b4808e7 into hibernate:main Sep 3, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant