In Spring Boot, _____ annotation is used to map HTTP POST requests onto specific handler methods.
- @Controller
- @GetMapping
- @PostMapping
- @RequestMapping
In Spring Boot, the @PostMapping annotation is used to map HTTP POST requests onto specific handler methods in a controller class. When you apply this annotation to a method, it tells Spring that this method should be invoked when an HTTP POST request with a matching URL is received. It's a key annotation for handling POST requests in a RESTful API.
Loading...
Related Quiz
- In Spring Boot, the _____ annotation is used to conditionally enable a configuration based on the presence of a specific property.
- How can a custom auto-configuration be created in Spring Boot?
- How can you configure property sources in a specific order in Spring Boot for resolving properties?
- How can the use of HTTP/2 in a Spring Boot application improve its performance?
- What strategies can be employed in Spring Boot to handle database connection failures and retries?