It would be nice to find a way to avoid specifying explicitly HandlerFunction lambda type for Kotlin user since they won't be able to fix this for Kotlin 1.1 (see this explanation on KT-14923).
Possible solutions are :
- Provide Kotlin specific API for the router
- Provide Kotlin extensions for RouterFunction and RouterFunctions
- Modify Java API signature to avoid this issue (unlikely but this is a possible solution)