Skip to content

Annotate auto configurations with spring's @ConditionalOnWebApplication #1041

@SonReimer

Description

@SonReimer

Spring-Boot offers the possibility to start an application as web application with an embedded server or as a standalone application by setting the property
spring.main.web-application-type=none
There are several scenarios that require doing so. Examples are creating a db-creation/update script from hibernate or running a preload without starting the server or dropping the schema in development.
Spring itself uses the annotation @ConditionalOnWebApplication in it's configuration class ServletWebServerAutoConfiguration and I think the vaadin configurations SpringBootAutoConfiguration and SpringSecurityAutoConfiguration should follow the same way.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions