From: Lincoln B. I. <lin...@gm...> - 2009-08-31 05:18:25
|
The client side proxy framework bails out on boolean typed return values, using 1.1.GA: @GET @Path("/{id}/password") @Consumes("text/plain") @Produces("text/plain") public boolean passwordIs(final @PathParam("id") long id, @QueryParam("p") final String password); Using object "Boolean" return value works fine: public Boolean passwordIs(final @PathParam("id") long id, @QueryParam("p") final String password); Exception occurs at: java.lang.ClassCastException at java.lang.Class.cast(Class.java:2990) at org.jboss.resteasy.util.TypeConverter.getType(TypeConverter.java:76) at org.jboss.resteasy.plugins.providers.DefaultTextPlain.readFrom(DefaultTextPlain.java:38) at org.jboss.resteasy.core.interception.MessageBodyReaderContextImpl.proceed(MessageBodyReaderContextImpl.java:105) at org.jboss.resteasy.plugins.interceptors.encoding.GZIPDecodingInterceptor.read(GZIPDecodingInterceptor.java:46) at org.jboss.resteasy.core.interception.MessageBodyReaderContextImpl.proceed(MessageBodyReaderContextImpl.java:108) at org.jboss.resteasy.core.messagebody.ReaderUtility.doRead(ReaderUtility.java:107) at org.jboss.resteasy.client.core.BaseClientResponse.readFrom(BaseClientResponse.java:229) at org.jboss.resteasy.client.core.BaseClientResponse.getEntity(BaseClientResponse.java:190) at org.jboss.resteasy.client.core.BaseClientResponse.getEntity(BaseClientResponse.java:149) at org.jboss.resteasy.client.core.ClientInvoker.extractEntity(ClientInvoker.java:167) at org.jboss.resteasy.client.core.ClientInvoker.invoke(ClientInvoker.java:109) at org.jboss.resteasy.client.core.ClientProxy.invoke(ClientProxy.java:59) at $Proxy28.passwordIs(Unknown Source) at com.ocpsoft.socialpm.jsf.validation.CurrentUserPasswordValidator.validate(CurrentUserPasswordValidator.java:35) |