AnnotationMethodHandlerAdapter should also implement Ordered interface [SPR-6516] #11182
Labels
in: web
Issues in web modules (web, webmvc, webflux, websocket)
type: enhancement
A general enhancement
Milestone
Pavel Marinchev opened SPR-6516 and commented
The initHandlerAdapters(...) method in the DispatcherServlet class expects all the discovered adapters being sorted. It tries to keep them in sorted order. That's nice and makes sense. BTW, this strategy is working fine also for HandlerMapping implementations.
The bad thing is that the default implementation of HandlerAdapter interface being used for the annotation driven context (AnnotationMethodHandlerAdapter) doesn't support ordering. That makes some inconveniences for our team dealing with several contexts.
It would be nice if the AnnotationMethodHandlerAdapter class could also implement Ordered interface so that the DispatcherServlet could keep defined ordering for the handler adapters.
Thanks in advance!
Pavel
Affects: 3.0 RC3
Referenced from: commits f72769a
The text was updated successfully, but these errors were encountered: