Mô tả

Backend engineering is an art. During my 18 years career working with and building backend applications, I discovered that certain communication design patterns keep emerging. There are only handful of ways clients communicate with backend applications, although they might be more, I believe the patterns I discuss in this course are the most common. Examples of these patterns are request-response, publish-subscribe, short and long and push.

Based on these communication design patterns, engineers may use a number of protocols for concrete communication. While core transport vehicles are limited to either TCP or UDP, tons of industry specific protocols are built on top of these two to address certain problems and use cases. Examples of these high level protocols are HTTP/1.1, HTTP/2, HTTP/3, gRPC, WebRTC and many more. Other transport protocols like QUIC was built on top of UDP to bring HTTP/2 streaming down at the transport level. Each protocol has its pros and cons and fits certain use cases. In the course, I discuss the top common protocols and provide examples and demos where applicable.

Before the client can send a request, it has to establish a connection to the backend. Understanding how the connection is established, and what parts of connection establishment is done at kernel and what parts are done at the backend application process is critical. How the connection is then accepted by the backend application and how it can accept connections as fast as possible so the kernel queue doesn’t get full otherwise clients can no longer connect.

After the connection is established the client sends the request, but what happens exactly in the backend application to read the request? What exactly is a request? Understanding the cost of parsing a request based on the protocol makes the engineer appreciate the work done and equip her with better tools to troubleshoot performance problems or bugs.

Once the request reaches the backend, the application has to execute the request. The backend has a buffet of design choices when it comes to the style of execution it can choose. Understanding the difference between a process and a thread, multi-process, multi-threaded and the correlation to the number of CPU cores or hardware threads is crucial to pick the right execution pattern. One does not have to stick with these patterns but can invent new ones that suits their needs.

This course is designed for engineers who have built backend applications, it is an intermediate — advance level course, certain programming and networking knowledge is required so I recommend taking my fundamentals of network engineering course before taking this course if you don’t have the networking skills. I hope you enjoy this course, and thank you so much for considering it.

Bạn sẽ học được gì

Learn the fundamentals of backend engineering

Backend communication design patterns

Understand how backend communication protocols work

Comprehend how OS Kernel communicate with Backend Applications

Operating System fundamentals (Thread, Process, async IO in linux)

Learn HTTP/1.1, HTTP/2, HTTP/3

Learn gRPC, WebRTC, WebSockets

Learn TLS 1.2, TLS 1.3, QUIC 0RTT

Yêu cầu

  • Intermediate programming skills (1-2 years)
  • Having built a backend application
  • Basic network fundamentals

Nội dung khoá học

8 sections

Introduction

5 lectures
Welcome
05:47
Who is this course for?
03:01
Course Outline
10:47
Course Notes
03:30
Download all slides, source code and references
00:04

Backend Communication Design Patterns

11 lectures
Backend Communication Design Patterns Intro
02:02
Request Response
27:37
Synchronous vs Asynchronous workloads
42:30
Push
19:59
Polling
14:13
Long Polling
10:11
Server Sent Events
13:18
Publish Subscribe (Pub/Sub)
16:37
Multiplexing vs Demultiplexing (h2 proxying vs Connection Pooling)
14:52
Stateful vs Stateless
22:42
Sidecar Pattern
21:33

Protocols

13 lectures
Protocols Intro
01:08
Protocol Properties
10:47
OSI Model
47:29
Internet Protocol
01:07:12
UDP
48:22
TCP
55:11
TLS
26:59
HTTP/1.1
31:11
WebSockets
21:21
HTTP/2
17:03
HTTP/3
27:58
gRPC
49:10
WebRTC
01:07:44

Many ways to HTTPS

7 lectures
HTTPS Communication Basics Intro
03:14
HTTPS over TCP with TLS 1.2
05:47
HTTPS over TCP with TLS 1.3
03:54
HTTPS over QUIC (HTTP/3)
02:23
HTTPS over TFO with TLS 1.3
01:55
HTTPS over TCP with TLS 1.3 and 0RTT
02:06
HTTPS over QUIC with 0RTT
01:46

Backend Execution Patterns

12 lectures
Backend Execution Patterns Intro
04:48
The Process and The Thread and how they compete for CPU time
27:46
How The Backend Accepts Connections
29:29
Reading and Sending Socket Data
21:22
The Listener, The Acceptor and the Reader
02:06
Single Listener, Acceptor and Reader Thread Execution Pattern
03:07
Single Listener, Acceptor and Multiple Readers Thread Execution Pattern
05:31
Single Listener, Acceptor, Reader with Message Load Balancing Execution Pattern
03:27
Multiple Accepter Threads on a Single Socket Execution Pattern
01:57
Multiple Listeners, Acceptors and Readers with Socket Sharding Execution Pattern
06:48
Backend Idempotency
06:24
Nagle's Algorithm
12:07

Proxying and Load Balancing

2 lectures
Proxy vs Reverse Proxy
20:05
Layer 4 vs Layer 7 Load Balancers
27:51

Extras

5 lectures
How ChatGPT uses Server Sent Events
44:07
How I design software
05:25
The Journey of a Request to the Backend
04:51
The Journey of a Request to the Backend (Video)
12:20
JSON Web Token (JWT), its Pros and Cons
56:37

Answering Your Questions

1 lectures
How does the Kernel manage backend connections?
04:55

Đánh giá của học viên

Chưa có đánh giá
Course Rating
5
0%
4
0%
3
0%
2
0%
1
0%

Bình luận khách hàng

Viết Bình Luận

Bạn đánh giá khoá học này thế nào?

image

Đăng ký get khoá học Udemy - Unica - Gitiho giá chỉ 50k!

Get khoá học giá rẻ ngay trước khi bị fix.