Open linux-china opened 5 years ago
@rstoyanchev Is RSocketRequester
the recommended functional alternative to MessageMapping
? If yes, how @MessageMapping("users.{user}.info")
and @DestinationVariable
would translate? Is there some special configuration to use for enabling composite metadata?
After discussing that with @rstoyanchev, we indeed miss a functional way to define RSocket routes. I think it is a too late for 5.2, but it would perfectly makes sense for 5.3 IMO. This should be implemented in Java with an additional Kotlin DSL like what with did on WebFlux.fn.
Now functional route is useful feature for Spring WebFlux and SpringMVC, and it's possible to add this feature for RSocket? Functional route is very convenient with functional style, especially for Kotlin, and all are functions and messages/events.
Two hard things: MessageMapping and payload data serialization. I like following style, and it's very useful sometimes.