Hi,
On 19/07/12 17:37, java kurious wrote:
I am getting following 406 error when sending a request to a REST service.

[#|2012-07-19T11:00:50.226-0400|INFO|glassfish3.1.1|javax.enterprise.system.std.com.sun.enterprise.server.logging|_ThreadID=128;_ThreadName=Thread-2;|DEBUG
[http-thread-pool-28181(4)] (WebApplicationExceptionMapper.java:62) -
*WebApplicationException
has been caught, status: 406*
javax.ws.rs.WebApplicationException
         at
org.apache.cxf.jaxrs.interceptor.JAXRSInInterceptor.processRequest(JAXRSInInterceptor.java:139)
         at
org.apache.cxf.jaxrs.interceptor.JAXRSInInterceptor.handleMessage(JAXRSInInterceptor.java:89)



INFO: DEBUG [http-thread-pool-8080(5)] (Headers.java:347) - Request
Headers: {*Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2*],
accept-charset=[ISO-8859-1,utf-8;q=0.7,*;q=0.7],
accept-encoding=[gzip,deflate],
accept-language=[en,en-gb;q=0.7,en-us;q=0.3], cache-control=[max-age=0],
connection=[keep-alive], Content-Type=[null], host=[localhost:8080],
keep-alive=[115], user-agent=[Mozilla/5.0 (X11; U; Linux i686; en-US;
rv:1.9.2.16) Gecko/20110323 Ubuntu/10.04 (lucid) Firefox/3.6.16]}

Can you provide a bit more info please ?
There has to be some more debug statements showing which resource methods have been checked.

How does the resource method signature look like ? I can see a wilcard (*/*) available in Accept, but what may happen for example is that some bean is returned but say it can not be handled by JAXB, etc

Cheers, Sergey



I saw the discussion on following link:

http://cxf.547215.n5.nabble.com/Jersey-CXF-compatibility-td5437938.html

I am wondering if the fix has been made and if so, which jar file do I need
to upgrade. Following are the direct dependencies I have declared related
to cxf:

        <dependency>
             <groupId>org.apache.camel</groupId>
             <artifactId>camel-cxf</artifactId>
             <version>2.9.1</version>
         </dependency>
         <dependency>
             <groupId>org.apache.camel</groupId>
             <artifactId>camel-cxf-transport</artifactId>
             <version>2.9.1</version>
         </dependency>
         <dependency>
             <groupId>org.apache.cxf</groupId>
             <artifactId>cxf-rt-frontend-jaxrs</artifactId>
             <version>2.6.1</version>
         </dependency>
         <dependency>
             <groupId>org.apache.cxf</groupId>
             <artifactId>cxf-bundle</artifactId>
             <version>2.6.1</version>
         </dependency>


Thanks for any help.

Reply via email to