Performance and bandwidth are limited, so we should use them as efficiently as possible. This video shows three ways of caching responses to help conserve bandwidth and maximize performance.
- [Instructor] Welcome to the last video…of this course that deals with caching.…In the previous video,…we looked at API versioning.…In this video,…we are going to take a look at how caching is done in HTTP,…we will look at in-memory data stores,…and finally, we will look at reverse proxy caches.…To demonstrate cashing in HTTP,…let's open Google Chrome…and search for "catching in HTTP."…We will open the first result.…Now, let's open developer tools…and go to the network tab.…
Let's check disable cache and refresh the page.…We can see that the browser downloaded…63.1 kilobytes of data.…Now, let's uncheck it and try again.…This time the browser only downloaded 289 bytes of data.…Let's disable the cache one more time and hit refresh.…We will click on the request.…We can see that the browser sent…the Cache-Control no-cache header.…This tells all the intermediary caches…to obtain a new copy of the document…from its origin.…
If we look at the Response header,…we see a Cache-Control max-age equal 21,600.…The server is telling us that the page…
This Node.js training course gives you an overview of a RESTful API and the logical steps of building one. It explores three different APIs, focusing on their similarities and differences to effectively implement one. Author Saleh Hamadeh starts off by defining APIs, showing how they can be built on top of HTTP and listing the properties that make an API RESTful. Then learn how to develop Twitter Notes, a sample web application that lets its users leave notes for their Twitter friends. You'll use Twitter's API to implement a login flow and then design a web API. In addition, you'll get a closer look at two other real-world APIs—Facebook API and GitHub API. Finally, learn some best practices to keep APIs secure, maintainable, and efficient.
- Identifying REST resources
- Setting up the development environment
- Consuming a RESTful API
- Creating an OAuth login request
- Getting an access token
- Saving data in MongoDB
- Building a RESTful API
- Looking at APIs in the real world
- Best practices for building RESTful APIs