How to confirgure swagger to handle custom Controller-level PathVariable annotations?
问题 In my Spring (4.3.2) project I'm using Swagger (2.7.0) to automatically generate docs and swagger-ui for my project. This worked great so far. But now I determined that I need to be able to declare Path Variables at the Controller level (not method level). And I need to teach swagger to discover these path variables and add them to docs and swagger-ui. I've created custom annotation @Target(ElementType.TYPE) @Retention(RetentionPolicy.RUNTIME) public @interface HasCommonPathVariable { /** *