Access the full course here: javabrains.io/courses/spring_bootquickstart
Learn how to make a POST REST API work using Spring MVC.
84 Comments on "Spring Boot Quick Start 19 – Creating a new resource using POST"
How are you running your server with no main(String args) method? I have the same code as you and mine will not even launch because there's no main method.
There is a main method since it is Spring Boot
@PostMapping("/topics") does the trick ,working fine
I remember that in one of our tutorials, you corrected that if the there is no default mapping method, If just put url in the request mapping annotation, it will mapping all http request method, not only GET. Please let me know if I am wrong.
Great tutorials, easy to follow.. but one thing, kindly increase the code font size so that it'll be easily visible on phone
Great tutorials ..
what if post body has garbage value ? non json or say, new parameter
In CodeChannels.com, you can learn to code by watching videos and stay up to date with latest code shows, events and tutorials aggregated from various leading developer communities.
Copyright 2016 By CodeChannels.com All rights reserved.