JAX-RS Response.seeOther needs empty entity() on Tomee 8

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

JAX-RS Response.seeOther needs empty entity() on Tomee 8

semanticfire
Hi,

I have some @POST JAX-RS services which were running fine in Tomee 7
After the post I redirect to the newly created reasource with

return Response.seeOther(newResourceURI).build();

This works fine on Tomee 7

Tomee 8 throws an exception:

WARNING - Interceptor for
{http://services.browser.firegraph.info/}ViewService has thrown exception,
unwinding now
java.lang.IllegalArgumentException: bean
        at org.apache.bval.util.Validate.notNull(Validate.java:38)
        at org.apache.bval.jsr.job.ValidateBean.<init>(ValidateBean.java:35)
        at
org.apache.bval.jsr.job.ValidationJobFactory.validateBean(ValidationJobFactory.java:52)
        at org.apache.bval.jsr.ValidatorImpl.validate(ValidatorImpl.java:53)
        at
org.apache.cxf.validation.BeanValidationProvider.doValidateBean(BeanValidationProvider.java:149)
        at
org.apache.cxf.validation.BeanValidationProvider.validateReturnValue(BeanValidationProvider.java:135)
        at
org.apache.cxf.validation.BeanValidationOutInterceptor.handleValidation(BeanValidationOutInterceptor.java:43)
        at
org.apache.cxf.validation.AbstractValidationInterceptor.handleMessage(AbstractValidationInterceptor.java:83)
        at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
        at
org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(OutgoingChainInterceptor.java:90)
        at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
( there is more )

To prevent this error I need to add an empty entity:
return Response.seeOther(newResourceURI).entity("").build();

I cannot find any documentation or explanation for this.
Any help is greatly appreciated!

Bart



--
Sent from: http://tomee-openejb.979440.n4.nabble.com/TomEE-Users-f979441.html