Spring supports for Kotlin
Due to its stunning features, Kotlin has rapidly grown in popularity, and many frameworks have started supporting it. The Spring Framework has allowed the development of Spring applications with Kotlin since version 5. Though Kotlin is fully interoperable with Java, you can write an application with pure and fully idiomatic Kotlin code. The diverse range of Kotlin features enhances productivity and combines well with Spring for application development.
As we have seen, the extension function in Kotlin is a non-intrusive way of providing a better alternative to the utility class or creating a class hierarchy for adding new features. Spring has used this feature to apply new Kotlin specific capabilities to existing Spring APIs. It is mainly used for dependency management. In the same way, Spring has also made framework APIs null safe to take full advantage of Kotlin.
Even Spring Boot has first-class Kotlin support, starting from version 2.x. This means you can write...