1.在浏览器上输入:localhost:8080/login.html
2.找到login.html
3.里面有form表单的
action="/login"。method=“post”,form提交到/login路径
4.根据/login路径,匹配web.xml,发现/login,通过/login找到LoginService
5.实例化Servlet对象
6.根据method=“post”,找到doPost方法
7.根据request拿到浏览器页面提交的数据
8.根据response给浏览器响应
到此servlet工作结束了
9.tomact拿到response后,根据http协议渲染到浏览器页面。