Files
spring-soap/spring-boot-modules/spring-boot-3-native/src/main/java/com/baeldung/sample/BoundaryConfiguration.java
Ralf Ueberfuhr 4ea66b59ce BAEL-5951: Spring Boot 3 Sample for Native Image builds incl. Runtime Hints (#13047)
* Update Spring Boot, Spring Native and Native Maven Plugin versions

* BAEL-5951: Spring Boot 3 Sample for Native Image builds incl. Runtime Hints

* BAEL-5951: Configure POMs and add Swagger UI runtime hints

* BAEL-5951: Remove Swagger UI runtime hints

* BAEL-5951: Remove Spring Boot3 parent POM from profiles because of JDK17 dependency during build (building the parent POM is even not necessary)

* BAEL-5951: Add tests

* BAEL-5951: Fix tests (PMD naming conventions)
2022-11-24 09:47:54 +01:00

24 lines
709 B
Java

package com.baeldung.sample;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
@Configuration
public class BoundaryConfiguration {
@Bean
public WebMvcConfigurer webMvcConfigurer() {
return new WebMvcConfigurer() {
@Override
public void addViewControllers(ViewControllerRegistry registry) {
registry
.addViewController("/")
.setViewName("redirect:/index.html");
}
};
}
}