resteasy

Problem with RestEasy and JSON

Hi, I am using RestEasy to marchal entities to JSON. That works okay but somehow every thing is represented as a String. e.g. @XmlRootElement(name="TestObject") public class TestObject { private Long value; public Long getValue(){ return value; } } Instead of creating something like: {TestObject:{value:1234}} It ...

How to instantiate a Home interface in a Seam Rest service if the Home interface has an User reference?

Hi, I am developing my first Seam + Android application and I am facing some new scenarios as expected. Now specifically for this app, I decided not to keep any state because probably 80% to 90% of the server calls on the REST service will be specifically to do a simple synchronization and the client is gone for a while, so there is(p...

Integrating Spring-MVC for page navigation & RESTEasy for REST service calls (Ajax)

Hi, I'm on a project that requires Spring-MVC for page navigation (possibly with webflow) where certain pages use RESTEasy to make Ajax calls (with JSON). I found an approach on DZone JavaLobby and followed it's approach (server is JBoss): I have configured the project so that it uses Spring MVC for page navigation and REST calls as re...

HTTP 500 Response with Body?

Hi, I have a RESTEasy service that returns a HTTP 500 when a server side error occurs. I manage to attach a body to the HTTP response in order to give more details about the error. So the response that comes out of the service looks something like this HTTP/1.1 500 Internal Server Error Server: Apache-Coyote/1.1 Content-Type: applicat...

Rest Easy Client Framework value lost after unmarshaling

Yesterday I tried to use the client side of the RestEasy framework. The interface has a method: @PUT @Path("document/autoincrement") @Consumes("application/xml") BaseClientResponse<String> insertPointOfInterest(PoiDocument poiDocument); and the call to some (Jersey) rest service looks like: String restServerServiceUrl = "http://m...

File upload in Resteasy

How to upload files using RESTEasy framework ? ...