I'm trying to use resteasy to serve out some entities fetched by spring-hibernate.
I've configured one method which returns a POJO and works as expected:
@GET @Path("/test") @Produces(MediaType.APPLICATION_XML) public Episode getTestEpisode() { Episode e = new Episode(); e.setEpisodename("test"); return e; }
<episode episodeId="0"> <combinedEpisodenumber>0.0</combinedEpisodenumber> <combinedSeason>0</combinedSeason> <episodename>test</episodename> <episodenumber>0</episodenumber> <seasonId>0</seasonId> <seasonnumber>0</seasonnumber> </episode>
Could not find MessageBodyWriter for response object of type: com.company.domain.Episode_$$_javassist_27 of media type: application/xml