When no API version is provided, static resources fail to load

I am experimenting with the API Versioning feature introduced in Spring 7.

I have an image file named foo.png under the resources/static directory.
However, when I try to access http://localhost:8080/foo.png in the browser, the image cannot be loaded.

In my case, the HandlerMappings are evaluated in the following order:

  1. RouterFunctionMapping (with ApiVersionStrategy)
  2. RequestMappingHandlerMapping (with ApiVersionStrategy)
  3. WelcomePageHandlerMapping
  4. BeanNameUrlHandlerMapping
  5. WelcomePageNotAcceptableHandlerMapping
  6. SimpleUrlHandlerMapping

I expect the image resource to be handled by SimpleUrlHandlerMapping. However, due to the ordering, the request fails earlier in the initApiVersion(HttpServletRequest) method of RouterFunctionMapping.