Skip to content

Provide support for Kotlin KClass parameter in SpringApplication.run() #8511

@sdeleuze

Description

@sdeleuze

It would be nice to support natively Kotlin KClass parameter to allow writing SpringApplication.run(FooApplication::class, *args) in Spring Boot 2.0.

I could be implemented using classpath detection, would avoid java.lang.IllegalArgumentException: Invalid source type class kotlin.reflect.jvm.internal.KClassImpl error that Kotlin users get by default and would provide more idomatic Kotlin code than the current SpringApplication.run(FooApplication::class.java, *args).

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: supersededAn issue that has been superseded by another

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions