How to Build Rest API Identify Resources: (/user, /user/{id}) etc. Identify Actions (GET, POST, PUT, DELETE, PATCH etc.) Defining Request and Response Structure Define Response Status( 200 as Ok, 404 as Page Not Found, 500 Internal Server Error) 400 Series Errors: Client Side Error 500 Series Errors: Server Side Error Best Practices for Rest API 1.Thinking on Consumer Perspective 2. validation 3 Internationalizations -i18n 4. Exception Handling 5. HATEOAS 6. Versioning 7. Documentation 8. Content Negotiation etc. Internal Working of Spring Boot 1. How to Handle Request in Spring Boot? Dispatcher Servlet- Front Controller Pattern Mapping Servlets: dispatcher Servlet urls=[/] ( as dispatcher servlet is mapped to the [/] root URL) If you search for Mapping servlets you will find out the given below string in logs which is telling to you dispatcher servlet is ma...
Comments
Post a Comment