my dog learned polymorphism*
The moose likes Servlets and the fly likes Getting error “java.io.IOException: Server returned HTTP response code: 406”, when calling servlet Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Getting error “java.io.IOException: Server returned HTTP response code: 406”, when calling servlet " Watch "Getting error “java.io.IOException: Server returned HTTP response code: 406”, when calling servlet " New topic
Author

Getting error “java.io.IOException: Server returned HTTP response code: 406”, when calling servlet

misko mis
Greenhorn

Joined: Jul 08, 2013
Posts: 1
I am working on client-server application. I am getting error: "java.io.IOException: Server returned HTTP response code: 406" when requesting method from servlet, to get object with selected name. On my server side I got following code in my DataController:



part of source code of my client where I am calling method getHarnessType:



after proceeding last line I am getting already mentioned error... interesting is, that when i change return type of method getHarnessType to String like:



and pass only String value to client (not whole object), everything works fine

full stack trace:




i tried to add and i get this message: ...The resource identified by this request is only capable of generating responses with characteristics not acceptable according to the request "accept" headers....
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Getting error “java.io.IOException: Server returned HTTP response code: 406”, when calling servlet
 
Similar Threads
reaching the catch in readOrders();
Calling Struts from standalone Java application
how to use parseInt()
Acces bean class property through a JButton
Acces bean class property through a JButton