From the course: Building Java Microservices with gRPC
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
How is HTTP/2 better?
From the course: Building Java Microservices with gRPC
How is HTTP/2 better?
- [Instructor] Now that we know the limitations of HTTP/1 protocol, let us see how HTTP/2 works. We know by now that it is a binary protocol and the data transmitted over it is in a binary format. In order to understand the working mechanism of HTTP/2, we need to know three key terms: a stream, a message and a frame. A stream is a bidirectional flow of data between the client and the server. It consists of a set of messages, and each stream is uniquely identified by a stream ID. The next term is a message. A message is a sequence of frames that correspond to your HTTP request or the response. And then we have a frame. A frame is the smallest unit of data that contains very specific type of information. It has a header and a body. The frame header contains the stream ID to determine which stream the frame belongs to. The body, in turn, can contain the HTTP header and the actual payload, which is the data. So between the…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.