springmvc流程

AnnotationAwareAspectJAutoProxyCreator

org.springframework.web.servlet.handler.AbstractHandlerMethodMapping#initHandlerMethods

Method RequestMappingInfo 映射关系

mappingLookup.put(RequestMappingInfo, HandlerMethod)

MultiValueMap<String, T> urlLookup = new LinkedMultiValueMap()
URL list<RequestMappingInfo>

先找urlLookup集合 找到合适的RequestMappingInfo 在去mappingLookup集合查找HandlerMethod对象

HandlerMethod handlerMethod = this.lookupHandlerMethod(lookupPath, request)
根据url找到多个RequestMappingInfo 根据 RequestMappingInfo 获取 HandlerMethod

如何从多个RequestMappingInfo中查找适合的RequestMappingInfo 主要通过 HttpServletRequest request去匹配

posted @ 2020-08-08 15:40  沙漠里的小鱼  阅读(71)  评论(0编辑  收藏  举报