Generic Kotlin controllers got broken in 6.1.5 #32510
Labels
in: web
Issues in web modules (web, webmvc, webflux, websocket)
theme: kotlin
An issue related to Kotlin support
type: regression
A bug that is also a regression
Milestone
Affects: 6.1.5
Generic controllers written in Kotlin stopped working after the upgrade to 6.1.5 from 6.1.4 with:
It seems that the issue was introduced in c1d4b61 when the check for
instanceof KClass<?>
has been removed.KType.classifier
returnsKTypeParameter
for the generic arguments of controller methods and the cast fails.Here is the reproduction example: https://github.com/utikeev/spring-generic-controller-6.1.5-issue
One can check that with Spring Boot 3.2.3
SpringGenericControllerApplicationTests
passes successfully, while with the Spring Boot 3.2.4 the test fails with the aforementioned error.The text was updated successfully, but these errors were encountered: