You’ve seen examples of servlet mapping in the Deployment Descriptors we’ve used in earlier chapters, beginning with the tutorial.
Every servlet mapping has two parts—the <servlet> element and the <servlet-mapping> element. The <servlet> defines a servlet name and class, and the <servlet-mapping> defines the URL pattern that maps to a servlet name defined somewhere else in the DD.