[hibernate-dev] WildFly BeanValidationCdiIntegrationTestCase test failure with ORM 5

Scott Marlow smarlow at redhat.com
Wed Jul 8 10:41:03 EDT 2015


Steve,

I created HHH-9905 for this, which I was able to workaround with a quick 
hack (set the missing "javax.persistence.validation.factory" property in 
the ConfigurationService).  I was able to pass the WildFly test with the 
workaround.

Steve, is that the right fix?  I assigned the jira to you.  Can we fix 
this for the CR2 build?  If we use the hack workaround, it will probably 
be coded a little different (the hack worked in the debugger but there 
is probably a more elegant way to code it).

Scott

On 07/08/2015 09:53 AM, Hardy Ferentschik wrote:
> Hi,
>
>> http://pastebin.com/4X0h1VPA is the call stack in.  We are in the second
>> bootstrap phase, which is good.  The validator factory is passed into the
>> integration properties but we are only checking the persistence unit
>> properties in ORM 5.  Since we are not looking in the integration properties
>> for the "javax.persistence.validation.factory", we are not seeing it.  So
>> your are right on the money, great suggestion.
>
> I am not sure how this all maps to the different phases and properties types, but
> the JPA specs says in 3.6.2 Providing the ValidatorFactory -
>
> "In Java EE environments, a ValidatorFactory instance is made available by the Java EE container.
> The container is responsible for passing this validator factory to the persistence provider via the
> map that is passed as an argument to the createContainerEntityManagerFactory call. The
> map key used by the container must be the standard property name javax.persistence.validation.
> factory"
>
> I am not sure where the properties of this map end up during the current bootstrapping process,
> but where ever that is, that's where we have to look in TypeSafeActivator (and potentially ask us
> the question whether it is the right place).
>
>> I'll check next why the
>> EntityManagerFactoryBuilder.withValidatorFactory(ValidatorFactory) is also
>> ignored.
>
> Sure. Seems we have a solid lead now.
>
> --Hardy
>


More information about the hibernate-dev mailing list