79424949

Date: 2025-02-09 13:27:28
Score: 2
Natty:
Report link

You have to import @RestController and @RequestMapping from:

org.springframework.web.bind.annotation.RequestMapping;
org.springframework.web.bind.annotation.RestController;

Additionally, you need to set the main class properly:

mainClass.set('webserver.blog.BlogApplication');

As you can see below, my Spring app has been started successfully without any errors.

enter image description here

my build.gradle file

enter image description here

Reasons:
  • Probably link only (1):
  • Has code block (-0.5):
  • User mentioned (1): @RestController
  • User mentioned (0): @RequestMapping
  • Low reputation (0.5):
Posted by: Syed