, "xml" "text/xml", "application/xml". , , "favorPathExtension" "ContentNegotiationViewResolver" true ( !)
EDIT: GIT location - git://github.com/bijukunjummen/mvc-samples.git, , mvn tomcat: run, json http://localhost:8080/mvc-samples/rest/customers/teddy.json xml http://localhost:8080/mvc-samples/rest/customers/teddy.xml, JAXB2, XStream, JAXB. , , , JAXB Customer, Spring JSON, XML, ( , XMLRootElement Customer), , XML, . , , - XStream.
2: ! , xml, , json . , AnnotationMethodHandlerAdapter @ResponseBody , ViewResolvers MessageConverters, ContentNegotiatingViewResolver, @ModelAttribute , @ResponseBody, Resolvers. git@github.com:bijukunjummen/mvc-samples.git , . Spring, Spring , .