Springboot 源码分析 —— @Endpoint 注解生效原理解析_开心小蜗牛的博客-CSDN博客
WebMvcEndpointManagementContextConfiguration
1)、这里是向容器注入自定义的 HandlerMapping,供 DispatcherServlet 调用,DispatcherServlet 根据各个 HandlerMapping 做实际的请求分发
2)、webEndpointServletHandlerMapping 方法,向容器注入 WebMvcEndpointHandlerMapping,由 DispatcherServlet 调用,转发请求到真实的endpoint中的特定operation中
2.1)、通过WebEndpointsSupplier获取所有的web类型endpoints(@Endpoint、@WebEndpoint 注解),WebEndpointsSupplier实例定义配置是在WebEndpointAutoConfiguration中
2.2)、通过ServletEndpointsSupplier获取所有servlet类型endpoints(@ServletEndpoint 注解),ServletEndpointsSupplier实例定义配置是在WebEndpointAutoConfiguration中