Skip to Content
Istio:快速入门
book

Istio:快速入门

by Lee Calcote, Zack Butcher
July 2025
Intermediate to advanced
272 pages
3h 22m
Chinese
O'Reilly Media, Inc.
Content preview from Istio:快速入门

第 3 章 Istio 一览

本作品已使用人工智能进行翻译。欢迎您提供反馈和意见:translation-feedback@oreilly.com

随着企业对容器部署的操作日趋成熟,许多企业将在其环境中使用服务网格。这一话题在 Cloud 本机生态系统中引起了巨大反响。目前,许多管理员、操作员、架构师和开发人员都在寻求对如何、何时以及为何采用服务网格的理解和指导,让我们来看看 Istio。

正如你在第 2 章中了解到的,Istio 与其他服务网格一样,为现代基础架构引入了一个新的层,为实现稳健且可扩展性强的应用创造了潜力,并可对其进行细粒度控制。如果你正在运行微服务,随着你部署越来越多的微服务,这些挑战就会加剧。不过,您可能不会运行微服务。尽管服务网格的价值在微服务部署中体现得淋漓尽致,但 Istio 也能轻松处理直接运行在虚拟机和裸机服务器操作系统上的服务。

服务网格架构

从高层来看,包括 Istio 在内的服务网格架构通常包括两个平面:控制平面和数据平面,而第三个(管理)平面可能位于现有/基础设施系统中。 Istio 的架构遵循了这一范式。图 3-1展示了按平面划分的关注点。

有关服务网格部署模型和演进架构方法的更全面解释,请参阅《企业服务网格架构之路》

iuar 0301
图 3-1. Istio 和其他服务网格由两个平面组成。通常会部署第三个平面,以便在异构环境中实现额外的 Network+ 智能并方便管理。

平面

Istio 的数据平面拦截请求中的每个数据包,并负责健康检查、路由选择、负载平衡、身份验证、授权和生成可观测信号。 在条带中运行时,服务代理是透明插入的,当应用程序进行服务对服务调用时,应用程序并不知道数据平面的存在。数据平面负责集群内通信以及入站(entress)和出站(entress)集群 网络流量。无论流量是进入还是离开网格,应用服务流量都会首先被引导到服务代理进行处理。有了 Istio,流量会被 iptables 规则透明拦截并重定向到服务代理。Istio 数据平面涉及系统中的每个数据包/请求,负责服务发现、健康检查、路由选择、负载平衡、身份验证、授权和可观察性。

Istio 中的控制平面为服务代理提供单点管理,,这些服务代理需要编程配置才能得到有效管理,并在整个环境(如容器集群)中重新安排服务时实时更新配置。控制平面为网状结构中的服务提供策略和配置,将一组孤立、无状态的代理转变为服务网状结构。它们不直接接触网状结构中的任何网络数据包;控制平面在条带外运行。控制平面通常有 CLI 和用户界面 (UI),每个界面都提供了访问集中式 API 的权限,以便全面控制代理行为。 您可以通过其 API 自动更改控制平面配置(例如,通过 CI/CD 管道),在实践中,配置最常见的是版本控制和更新。

Istio 控制平面具有以下功能:

  • 通过 API 为网格中的服务提供策略和配置,以便运营商指定所需的路由/弹性行为

  • 将一组孤立的无状态侧车代理组合成服务网格:

    • 数据平面消费本地化配置的 API

    • 数据平面的服务发现抽象

  • 使用 API 通过配额和使用限制指定使用策略

  • 通过证书签发和轮换提供安全性

  • 分配工作负载身份

  • 处理路由配置:

    • 不接触系统中的任何数据包/请求

    • 指定网络边界和访问方式

    • 统一遥测收集

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

TensorFlow.js学习手册

TensorFlow.js学习手册

Gant Laborde
Kafka权威指南(第2版)

Kafka权威指南(第2版)

Gwen Shapira, Todd Palino, Rajini Sivaram, Krit Petty
这才是服务设计

这才是服务设计

Marc Stickdorn, Markus Hormess, Adam Lawrence, Jakob Schneider
金融中的机器学习

金融中的机器学习

Posts & Telecom Press, Jannes Klaas

Publisher Resources

ISBN: 9798341663091