Bean validation troubleshooting tips
An application module does not start when a validation factory cannot be created.
There are various problems related to bean validation and the validation.xml file that might prevent the validation factory from being created and the application module to not start. The following messages that are logged in this case:
- An incorrect syntax or error is detected in the validation.xml file found in module_name. The following associated error message occurred: error_message
The message is caused by errors in the validation.xml file most likely because it does not conform to the validation schema definition.
- The BeanValidationService service is unable to create a ValidationFactory class because it was unable to load or instantiate the class, class_name in path, path_name, because the following error: error_message
This error occurs if any of the configuration setting classes that are defined in the validation.xml file are missing or unable to be loaded. Ensure that the class is available and on the application class path. Other class loader issues can also cause this error to occur. For more information about class loading, see the Class loader documentation.
- The BeanValidationService service is unable to create a ValidatorFactory class.
This error might occur if any of the constraint mapping files defined in the validation.xml file are not found in the module. Ensure that the defined constraint mapping XML files are available.
Related:
Bean validation in RAR modules Bean Validation Troubleshoot bean validation in RAR modules