|
When bootstrapping Bean Validation via Validation#byProvider(Class<?> provider), still the provider resolver is used to find a registered provider which is assignment compatible with the given class. I'm wondering why this is, can't we just instantiate the given provider type?
The current behavior requires a custom resolver in OSGi, also when explicitly bootstrapping Hibernate Validator, i.e. we already have the right provider class and don't need to find it anymore.
|