In the first chapter, we provided a little introduction to the Dispatcher servlet and you saw how to configure a Dispatcher servlet using the DispatcherServletInitializer
class. You learned that every web request first comes to the Dispatcher servlet. The Dispatcher servlet is the thing that decides which controller method the web request should be dispatched to. In the previous chapter, we created a welcome page that will be shown whenever we enter the URL http://localhost:8080/webstore/
in the browser. Mapping a URL to the appropriate controller method is the primary duty of the Dispatcher servlet.
So the Dispatcher servlet reads the web request URL and finds the appropriate controller method that can serve that web request and invokes it. This process of mapping a web request onto a specific controller method is called request mapping. And the Dispatcher servlet is able to do this with the help of the @RequestMapping
(org.springframework.web.bind.annotation.RequestMapping...