vaadin / spring

Spring integration for Vaadin
https://vaadin.com/start
174 stars 101 forks source link

Annotate auto configurations with spring's @ConditionalOnWebApplication #1041

Open SonReimer opened 2 years ago

SonReimer commented 2 years ago

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.