springmvc.xml为什么要写<mvc:annotation-driven/>而applicationContext.xml中就不用开启注解驱动
总结;
1,因为<mvc:annotation-driven/>代替了配置处理器映射器(HandlerMapping)和处理器适配器(HandlerAdapter)。
参考资料
springMvc为什么要加开启注解驱动? https://blog.csdn.net/weixin_42529699/article/details/88085405