I'm using springdoc-openapi with Kotlin and WebFlux.fn.
I wanted to use @RouterOperation annotation at every path in CoRouterFunctionDsl but I couldn't.
@Configuration
class UserRouter(private val userHandler: UserHandler) {
// @RouterOperations annotation works here.
@Bean
fun userRouter = coRouter {
("/v1").nest {
// I want to use @RouterOperation annotation here.
GET("/users", userHandler::getUsers)
// I want to use @RouterOperation annotation here.
GET("/users/{userId}", userHandler::getUserById)
// I want to use @RouterOperation annotation here.
POST("/users", userHandler::postUser)
}
}
}
There doesn't seem to be any relevant documentation about this.
How can I use @RouterOperation in coRouter DSL?