Spring MVC REST is not JAX-RS compliant. Does it matter? [closed] Spring MVC REST is not JAX-RS compliant. Does it matter? [closed] spring spring

Spring MVC REST is not JAX-RS compliant. Does it matter? [closed]


IMHO, if your web application returns JSON/XML only, there is no big difference. However, if some end points of your web application need to return HTML, Spring MVC is better. The reason I think so is that JAX-RS does not provide any MVC mechanism (AFAIK). Jersey (one of JAX-RS implementations) provides Viewable/Template to support MVC, but it is a Jersey-specific feature and not a part of JAX-RS specification.

Chapter 18. MVC Templates
https://jersey.java.net/documentation/latest/mvc.html

Also, this blog may give you some insights.

Jersey JAX-RS MVC Killed the Spring MVC Star
http://sleeplessinslc.blogspot.jp/2012/02/jersey-jax-rs-mvc-killed-spring-mvc.html
(The conclusion of the blog is different from its title, though.)


EDIT - here's the answer to the question asked:

Standardized annotations

As the 2nd link above says:

Jersey is a JAX-RS implementation, one could swap out Jersey for another provider like RestEasy if desired without much effort. Spring MVC on the other hand has REST web service support but the same is not a JAX-RS implementation and therefore one is tied to Spring MVC.