[
https://hibernate.onjira.com/browse/HV-573?page=com.atlassian.jira.plugin...
]
Hardy Ferentschik updated HV-573:
---------------------------------
Description:
In Resteasy, I inadvertently created a method
{code}
@FooConstraint(min=3,max=5)
public void postImposed(Foo foo){
}
{code}
and got
{noformat}
java.lang.RuntimeException: Unhandled primitive type.
at org.hibernate.validator.util.ReflectionHelper.boxedType(ReflectionHelper.java:722)
at
org.hibernate.validator.metadata.location.MethodConstraintLocation.typeOfAnnotatedElement(MethodConstraintLocation.java:74)
at
org.hibernate.validator.metadata.MetaConstraint.typeOfAnnotatedElement(MetaConstraint.java:92)
at
org.hibernate.validator.metadata.MetaConstraint.validateConstraint(MetaConstraint.java:82)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValueForGroup(ValidatorImpl.java:1120)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValueForGroup(ValidatorImpl.java:1082)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValueInContext(ValidatorImpl.java:1022)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValue(ValidatorImpl.java:245)
at
org.jboss.resteasy.plugins.providers.validation.GeneralValidatorImpl.validateReturnValue(GeneralValidatorImpl.java:71)
...
{noformat}
was:
In Resteasy, I inadvertently created a method
{code}
@FooConstraint(min=3,max=5)
public void postImposed(Foo foo)
{
}
{code}
and got
java.lang.RuntimeException: Unhandled primitive type.
at org.hibernate.validator.util.ReflectionHelper.boxedType(ReflectionHelper.java:722)
at
org.hibernate.validator.metadata.location.MethodConstraintLocation.typeOfAnnotatedElement(MethodConstraintLocation.java:74)
at
org.hibernate.validator.metadata.MetaConstraint.typeOfAnnotatedElement(MetaConstraint.java:92)
at
org.hibernate.validator.metadata.MetaConstraint.validateConstraint(MetaConstraint.java:82)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValueForGroup(ValidatorImpl.java:1120)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValueForGroup(ValidatorImpl.java:1082)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValueInContext(ValidatorImpl.java:1022)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValue(ValidatorImpl.java:245)
at
org.jboss.resteasy.plugins.providers.validation.GeneralValidatorImpl.validateReturnValue(GeneralValidatorImpl.java:71)
...
Need graceful handling of return value constraint applied to method
with void return type
-----------------------------------------------------------------------------------------
Key: HV-573
URL:
https://hibernate.onjira.com/browse/HV-573
Project: Hibernate Validator
Issue Type: Bug
Reporter: Ron Sigal
Priority: Minor
In Resteasy, I inadvertently created a method
{code}
@FooConstraint(min=3,max=5)
public void postImposed(Foo foo){
}
{code}
and got
{noformat}
java.lang.RuntimeException: Unhandled primitive type.
at org.hibernate.validator.util.ReflectionHelper.boxedType(ReflectionHelper.java:722)
at
org.hibernate.validator.metadata.location.MethodConstraintLocation.typeOfAnnotatedElement(MethodConstraintLocation.java:74)
at
org.hibernate.validator.metadata.MetaConstraint.typeOfAnnotatedElement(MetaConstraint.java:92)
at
org.hibernate.validator.metadata.MetaConstraint.validateConstraint(MetaConstraint.java:82)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValueForGroup(ValidatorImpl.java:1120)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValueForGroup(ValidatorImpl.java:1082)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValueInContext(ValidatorImpl.java:1022)
at
org.hibernate.validator.engine.ValidatorImpl.validateReturnValue(ValidatorImpl.java:245)
at
org.jboss.resteasy.plugins.providers.validation.GeneralValidatorImpl.validateReturnValue(GeneralValidatorImpl.java:71)
...
{noformat}
--
This message is automatically generated by JIRA.
For more information on JIRA, see:
http://www.atlassian.com/software/jira