Use REsteasy 3 and the new JAX-RS 2.0 client api. Then you just return a Response, check the status, and extract whatever you want.
On 8/20/2013 11:42 AM, Jason Novotny wrote: > Hi, > > Typically I have resteasy calls like: > > @POST > @Path("/blah/restcall") > ClientResponse<MyObject> restCall(); > > Where I expect to get MyObject back-- however, the third-party API I'm > using will flag the response code as 500 if it turns out to be an error, > in which case MyObject should really be ErrorObject. Is there a way to > handle this case easily? > > Thanks, Jason > > ------------------------------------------------------------------------------ > Introducing Performance Central, a new site from SourceForge and > AppDynamics. Performance Central is your source for news, insights, > analysis and resources for efficient Application Performance Management. > Visit us today! > http://pubads.g.doubleclick.net/gampad/clk?id=48897511&iu=/4140/ostg.clktrk > _______________________________________________ > Resteasy-users mailing list > Resteasy-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/resteasy-users > -- Bill Burke JBoss, a division of Red Hat http://bill.burkecentral.com ------------------------------------------------------------------------------ Introducing Performance Central, a new site from SourceForge and AppDynamics. Performance Central is your source for news, insights, analysis and resources for efficient Application Performance Management. Visit us today! http://pubads.g.doubleclick.net/gampad/clk?id=48897511&iu=/4140/ostg.clktrk _______________________________________________ Resteasy-users mailing list Resteasy-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/resteasy-users