Building REST APIs with Spring Boot

In the previous chapter, we looked at the basics of Spring Boot. In this chapter, we'll focus on building great Representational State Transfer (REST) APIs with Spring Boot.

Applications do not live alone. They talk to each other. Applications can be built in a wide range of languages—Java, C#, JavaScript, and more. How do we get these to talk to others? Web services is the answer. Initially, XML-based web services using Simple Object Access Protocol (SOAP) were the order of the day. In the last few years, web services built in the REST style have become popular.

In this chapter, we will answer the following questions:

  • What is REST?
  • Why is REST popular today?
  • How do you build REST APIs with Spring Boot?
  • What are the different request methods—GET, POST, and so on—and when do you use them?
  • How do you provide great exception handling and validations for your REST API?
  • How do you provide documentation for your REST API?
  • How do you implement advanced features for your REST API, such as Hypermedia as the Engine of Application State (HATEOAS), caching, and internationalization?
  • How do you deploy your REST API to the cloud?

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset