默认的只会导出注解有
org.springframework.stereotype.Controller或org.springframework.web.bind.annotation.RestController的类中的api.
当有导出未注解
org.springframework.stereotype.Controller或org.springframework.web.bind.annotation.RestController的类中的api的需求时,可以配置此规则
apiclass.is.spring.ctrl=true
spring_ctrl类中的api导出所有类中的api出现卡顿, 希望通过注释@spring_ctrl来控制哪些类会包含api, 那可配置为class.is.spring.ctrl=#spring_ctrl
Demo
/**
* @spring_ctrl
*/
@RequestMapping("/users")
public class UserController {
/**
* 获取用户信息
*
* @public
*/
@RequestMapping("/{userId}")
public UserInfo getUserInfo(@PathVariable Long userId) {
// 实现代码...
return userInfo;
}
}