I have a simple Spring Boot project with this Gradle build file:
apply plugin: \'java\' apply plugin: \'eclipse\' apply plugin: \'spring-boot\' apply plugin: \'w
You can use @RestController in your Spring Boot project instead of @Controller annotation. In this way you don't have to use @ResponseBody annotation in your method even if your method doesn't return any value.
@RestController
@Controller
@ResponseBody