When specified the Non-existent package using @ControllerAdvice(basePackages), has been applied to all controllers. [SPR-12510] #17115
Labels
in: web
Issues in web modules (web, webmvc, webflux, websocket)
status: backported
An issue that has been backported to maintenance branches
status: duplicate
A duplicate of another issue
Milestone
Kazuki Shimizu opened SPR-12510 and commented
e.g)
Above
@ModelAttribute
method has been applied to the all controllers.( e.g: controllers underio.github.kazuki43zoo.app
package).I think feel unnatural in this behavior.
This behavior is specification ?
As related information ..
When specified the Non-existent package using
@ComponentScan(basePackages)
, controller is not scanned.I think should be changed to the same behavior with
@CompnentScan
.How do think ?
Affects: 4.0.8, 4.1.2
Issue Links:
@ControllerAdvice
must contain at least one Controller ("duplicates")@ControllerAdvice
(basePackageClasses) do the prefix search by package name.Backported to: 4.0.9
The text was updated successfully, but these errors were encountered: