Title: is DispatcherServlet a controller in spring mvc?
Tags: spring;spring-mvc
Question: In Jsf FacesServlet works as a controller. I want to know what infact is controller in spring mvc is it dispatcherservlet or the class annotated as @controller?
Comment: It depends on point of view. This JSF-targeted answer also applies to Spring MVC: http://stackoverflow.com/q/5104094

Comment: in reality in spring mvc we have only one controller and it is DispacherServlet and the classes annotated @Controller are just normal classes.



{'source': 'StackExchangeDataset', 'subset': 'stackoverflow.com', 'metadata': {'AnswerCount': 0, 'CommentCount': 2, 'ContentLicense': 'CC BY-SA 3.0', 'CreationDate': '2016:00:08/10/16', 'FavoriteCount': None, 'PostTypeId': 1, 'Tags': '<spring><spring-mvc>', 'Title': 'is DispatcherServlet a controller in spring mvc?', 'ViewCount': 95, 'id': 38866457, 'user_AboutMe': None, 'user_AccountId': None, 'user_DisplayName': None, 'user_Reputation': None, 'user_Views': None, 'user_id': None}}