[hibernate-issues] [Hibernate-JIRA] Updated: (HHH-4968) Cannot deactivate default BeanValidationListener independently of DDL constraints generation (Vladimir Klyushnikov)
Emmanuel Bernard (JIRA)
noreply at atlassian.com
Tue Jun 15 06:18:04 EDT 2010
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-4968?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Emmanuel Bernard updated HHH-4968:
----------------------------------
Fix Version/s: (was: 3.5.x)
3.5.3
> Cannot deactivate default BeanValidationListener independently of DDL constraints generation (Vladimir Klyushnikov)
> -------------------------------------------------------------------------------------------------------------------
>
> Key: HHH-4968
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-4968
> Project: Hibernate Core
> Issue Type: Bug
> Components: annotations
> Affects Versions: 3.5.0-CR-2
> Environment: Hibernate 3.5.0-CR-2, Hibernate Validator 4.0.2.GA
> Reporter: Vladimir Klyushnikov
> Assignee: Emmanuel Bernard
> Priority: Minor
> Fix For: 3.5.3
>
> Attachments: BeanValidationActivator.patch
>
>
> Hi,
> I need to configure my custom BeanValidationListener instance through Spring, but I cannot deactivate default BeanValidationListener instance. It can be switched off only with DDL constraint generation. When I provide *DDL* value for *javax.persistence.validation.mode* it still activates default BeanValidationListener. When I provide *NONE* value it switches off both BeanValidationListener and DDL constraints. This is because of following code in *BeanValidationListener.java*:
> {code}
> public static void activateBeanValidation(EventListeners eventListeners, Properties properties) {
> ...
> if ( modes.contains( ValidationMode.NONE ) ) return;
> ...
> }
> {code}
> It should be changed to following:
> {code}
> if (!(modes.contains(ValidationMode.CALLBACK) || modes.contains( ValidationMode.AUTO))) return;
> {code}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list