Skip to Content
Google系统架构解密: 构建安全可靠的系统
book

Google系统架构解密: 构建安全可靠的系统

by Heather Adkins, Betsy Beyer, Paul Blankinship, Piotr Lewandowski, Ana Oprea, Adam Stubblefield
September 2021
Beginner to intermediate
392 pages
12h 13m
Chinese
Posts & Telecom Press
Content preview from Google系统架构解密: 构建安全可靠的系统
弹性设计
109
2.
限流
限流(参见《
SRE
Google
运维解密》中的第
21
章)通过延迟当前操作来间接修改客户
端的行为,以便推迟将来的操作。服务器收到请求后,可能会在处理请求之前等待,或
者一旦处理完请求,就在将响应发送到客户端之前等待。此方法降低了服务器从客户端
接收请求的速率(如果客户端按顺序发送请求),这意味着你可以重定向在等待期间节省
的资源。
与降低负载相似,你可以定制策略,将限流措施应用于特定的违规客户端,或者更普遍地
应用于所有的客户端。请求优先级和成本在选择限制哪些请求时起了作用。
3.
自动响应
服务器利用率的统计有助于确定何时应用降低负载和限流等控制措施。服务器的负载越
重,它可以处理的流量或负载就越少。如果激活控制机制的时间过长,则可能丢弃或限制
优先级较高的请求。
要有效地大规模管理这些降级控制,需要一个内部中央服务。你可以将有关功能和故障成
本的业务考虑因素转化为此服务的策略和信号。该内部服务还可以聚合客户端和服务的启
发式信息,以便近乎实时地将更新的策略分发到所有服务器。然后服务器可以根据服务器
利用率的规则应用这些策略。
自动响应的一些可能做法包括以下几种:
实施可响应式的限流信号,并尝试将流量转移到负载较低的服务器的负载均衡系统;
提供
DoS
保护,可在限流无效或流量具有破坏性时,帮忙向恶意客户端发出响应;
使用关键服务的重负载报告,触发将故障转移到备用组件的准备(本章后面的部分将讨
论这一策略)。
你还可以将自动化用于自发的故障检测:如果服务器确定它不能服务于某些类别甚至所有 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

管理Kubernetes

管理Kubernetes

Brendan Burns, Craig Tracey
Python机器学习基础教程

Python机器学习基础教程

Andreas C. Müller, Sarah Guido
解密金融数据

解密金融数据

Justin Pauley

Publisher Resources

ISBN: 9787115569257