|
|
|
|
|
|
This is a follow-up on https://hibernate.atlassian.net/browse/ HV-563 which added the ability to reset configuration streams to be re-used when calling {{Configuration#buildValidatorFactory()}} multiple times. This , however , won't work on IBM JVM because it closes streams when creating an {{ XMLEventReader }} out of them.
This causes test failures in {{org.hibernate.validator.test.internal.engine.ConfigurationImplTest}} - tests {{testReusableConfigurationWithNonResettableInputStream}} and {{testReusableConfigurationWithInputStream}}
Wrapping the configuration streams into a stream which ignores {{close()}} seems to resolve it - see https://github.com/jmartisk/hibernate-validator/commit/2060fb1e0e466155312d429001458d470a7d8251 but I wonder if not closing streams could lead to some resource leaks. Also perhaps this should be used only when IBM JVM is detected..
Also see HV-1007 for a related issue
|
|
|
|
|
|