I came across many tutorials using Jersey and Tomcat7 to implement rest web services. But I also see that tomcat provides web services support if you download catalina-ws.jar (look here). So I would like to ask if we can use only this jar in the project and call rest web services ? Has anyone used this before ?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
Jersey is JAX-RS (JSR-311) which is absolutely not the same as WebServices 1.2 (JSR-109), which is part of Java EE 5. Either install Jersey separately, or replace Tomcat by TomEE. You only get Apache CXF instead of Jersey.