0Pricing
gRPC & High Performance APIs · レッスン

サービスメッシュによるgRPCトラフィック管理

Istioなどのサービスメッシュを使い、サイドカープロキシ、インテリジェントルーティング、リトライ、カナリアリリースによってクラウド上のgRPCトラフィックを管理します。

「サービスメッシュによるgRPCトラフィック管理」はCoddyKit上の無料gRPC & High Performance APIsレッスンです。 これはレッスン4/4です。 下記で完全なレッスンを無料で読むことができます。その後、ブラウザ内の組み込みコードエディタと24時間対応のAIチューターでハンズオン演習できます。 これはgRPC & High Performance APIs学習パスの一部であり、ウェブとCoddyKitアプリ全体で進捗が同期されます。 gRPC & High Performance APIsコースには全4レッスンが含まれています。

このレッスンの一部はまだ翻訳されておらず、英語で表示されています。

Why a Service Mesh

As gRPC microservices multiply, cross-cutting concerns — routing, retries, mTLS, observability — clutter every service. A service mesh moves these into the platform layer.

The Sidecar Proxy

A mesh injects a sidecar proxy (e.g. Envoy) next to each pod. All gRPC traffic flows through it, so the proxy can apply policy without changing app code.

Data Plane vs Control Plane

Two halves:

  • Data plane: the proxies that move traffic
  • Control plane: configures the proxies (Istiod in Istio)

You write high-level rules; the control plane programs each proxy.

gRPC-Aware Load Balancing

Plain L4 load balancers pin all streams of a connection to one backend, unbalancing gRPC. The mesh proxy is L7 and balances per-request, spreading RPCs evenly.

Defining a VirtualService

An Istio VirtualService routes traffic by rules — host, headers, or weights. Here all traffic goes to the v1 subset.

spec:
  hosts: ['orders']
  http:
  - route:
    - destination: { host: orders, subset: v1 }

Canary Releases by Weight

Split traffic by percentage to roll out a new version gradually and watch its error rate before shifting more.

route:
- destination: { host: orders, subset: v1 }
  weight: 90
- destination: { host: orders, subset: v2 }
  weight: 10

Automatic Retries

The mesh can retry failed RPCs without app code. Configure attempts and per-try timeout, and limit retries to safe (idempotent) methods.

retries:
  attempts: 3
  perTryTimeout: 2s
  retryOn: 'unavailable'

Timeouts and Circuit Breaking

Set request timeouts and outlier detection so unhealthy backends are ejected automatically, protecting the system from cascading failures.

outlierDetection:
  consecutive5xxErrors: 5
  interval: 30s

Built-in mTLS

The mesh issues and rotates certificates, encrypting all service-to-service gRPC with mutual TLS automatically — no app changes required.

Observability for Free

Because all traffic passes through proxies, the mesh emits metrics, distributed traces, and access logs for every gRPC call, feeding dashboards like Kiali and Grafana.

Trade-offs

Meshes add value but also cost:

  • Extra latency per hop via the sidecar
  • Higher resource usage
  • Operational complexity

Adopt when service count and policy needs justify it.

Quick Check

Test your mesh knowledge.

Recap

You learned mesh traffic management:

  • Sidecar proxies apply policy without app changes
  • L7 proxies load-balance gRPC per request
  • VirtualService rules enable canary releases by weight
  • Built-in retries, timeouts, circuit breaking, and mTLS
  • Free observability — at the cost of latency and complexity

よくある質問

「サービスメッシュによるgRPCトラフィック管理」レッスンは無料ですか?

はい。「サービスメッシュによるgRPCトラフィック管理」の完全なテキストはこのウェブで無料で読めます。インタラクティブに演習し(組み込みコードエディタと24時間対応のAIチューター)、gRPC & High Performance APIsコースの残りをアンロックするには、CoddyKit PROにアップグレードしてください。 gRPC & High Performance APIsコースには全4レッスンが含まれています。

「サービスメッシュによるgRPCトラフィック管理」で何を学びますか?

Istioなどのサービスメッシュを使い、サイドカープロキシ、インテリジェントルーティング、リトライ、カナリアリリースによってクラウド上のgRPCトラフィックを管理します。 ブラウザで直接実行するハンズオンコードでgRPC & High Performance APIsを演習し、24時間対応のAIチューターがレッスンを進める中での質問に答えます。

gRPC & High Performance APIsを始めるのに経験は必要ですか?

事前経験は必要ありません。CoddyKitのgRPC & High Performance APIsは初級者から上級者向けに構成されているため、ここから始めるか最初から始めて、自分のペースで進むことができます。 これはレッスン4/4です。

「サービスメッシュによるgRPCトラフィック管理」レッスンにはどのくらい時間がかかりますか?

ほとんどのCoddyKitレッスンは約5~10分かかります。各レッスンはコンパクトでインタラクティブなので、着実に進歩し、ウェブとアプリ全体で正確に前回の場所から再開できます。

このgRPC & High Performance APIsレッスンでコードを書いて実行できますか?

はい。すべてのgRPC & High Performance APIsレッスンに組み込みコードエディタが含まれているため、ブラウザでリアルコードを書いて実行し、即座のAIフィードバックを取得できます。ローカル設定は不要です。

このコースのすべてのレッスン

  1. Kubernetes上のgRPC
  2. クラウドロードバランサー
  3. サーバーレスgRPC関数
  4. サービスメッシュによるgRPCトラフィック管理
← gRPC & High Performance APIsに戻る