Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
KubeCon NA 2024 Recap
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Kota Kimura
November 13, 2025
28
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
KubeCon NA 2024 Recap
Kota Kimura
November 13, 2025
More Decks by Kota Kimura
See All by Kota Kimura
Operating and Migrating OpenTelemetry Collector in a 100-Cluster-Scale Multi-Tenant Environment
kkk777
0
17
Getting Started kubernetes
kkk777
0
74
story about confronting node failure due to excessive memory consumption in kubelet
kkk777
1
67
k8s ecosystem management with using of Argo CD
kkk777
0
230
Featured
See All Featured
Java REST API Framework Comparison - PWX 2021
mraible
34
9.7k
Rebuilding a faster, lazier Slack
samanthasiow
85
9.7k
SEO Brein meetup: CTRL+C is not how to scale international SEO
lindahogenes
2
2.9k
HTML-Aware ERB: The Path to Reactive Rendering @ RubyCon 2026, Rimini, Italy
marcoroth
5
770
DevOps and Value Stream Thinking: Enabling flow, efficiency and business value
helenjbeal
1
400
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
2
460
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
508
140k
The World Runs on Bad Software
bkeepers
PRO
72
12k
SERP Conf. Vienna - Web Accessibility: Optimizing for Inclusivity and SEO
sarafernandez
2
1.6k
Game over? The fight for quality and originality in the time of robots
wayneb77
1
300
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
230
23k
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
550
Transcript
KubeCon NA 2024 Recap 「Extending the Gateway API: The Power
and Challenges of Policies」 CIU Development Div 木村 洸太
自己紹介 木村 洸太 - Kota Kimura • 株式会社サイバーエージェント グループIT推進本部 CIU
Development Div所属 • KaaS プロダクト AKE の開発・運用を担当 • 趣味はサウナ巡り @ k10krn
セッション概要 タイトル : 「Extending the Gateway API: The Power
and Challenges of Policies」 Gateway API を拡張する方法の1つのポリシーアタッチメント メカニズムに関して NGINX の独自ポリシーを実装した際に学んだ教訓を共有しながら説明
おさらい
(おさらい) Ingress API Ingress API • アプリケーションの L7ルーティングを設定するリソース 課題
• インフラ管理者、クラスタ管理者、アプリ開発者の それぞれで設定したい項目があり、責任分界点が不明瞭 • トラフィックの細かなルーティング管理が Ingress Controller 独自 の拡張機能で提供される形で、環境依存が発生する
(おさらい) NGINX Ingress の拡張機能 • Ingress の annotations に付与することで設定
Reference https://kccncna2024.sched.com/event /1i7ln (多すぎる....)
(おさらい) Gateway API Gateway API • ロール指向の設計 ◦ ペルソナごとに管理すべきリソースが
分かれている構成 • 細かなルーティング制御の実現 ◦ 標準の HTTPRoute Rules でヘッダーによる フィルタリングやタイムアウトなど設定可能 • L4/L7 ルーティングの提供 ◦ HTTPRoute ◦ GRPCRoute ◦ TLSRoute (Experimental) ◦ TCPRoute (Experimental) ◦ UDPRoute (Experimental) Reference: https://gateway-api.sigs.k8s.io/
(おさらい) Gateway API Ingress の課題 • インフラ管理者、クラスタ管理者、アプリ開発者の それぞれで設定したい項目があり責任分界点が不明瞭 ◦
→ Gateway API リソースモデルにより解決! • トラフィックの細かなルーティング管理が Ingress Controller 独自の拡張機能で提供される形で、環境依存が発生する ◦ → HTTPRoute の設定などで一部は解決! ◦ ただし標準で全ては解決しておらず、どのように拡張を行うのか (本セッションの内容)
セッション
Policy Attachment • Metaresource タイプの CRD ◦ Gateway API
では、標準的な方法でオブジェクトの振る舞いを拡張する Kubernetes オブジェクトを Metaresource と定義 ◦ 該当オブジェクトの spec 仕様内で記述できない設定を追加できる • ポリシーは大きく分けて2種類 ◦ Direct Policies ▪ https://gateway-api.sigs.k8s.io/geps/gep-2648/ ◦ Inherited Policies ▪ https://gateway-api.sigs.k8s.io/geps/gep-2649/ Policy Attachment は現在 GEP で議論中なので、本発表の内容の仕様から 将来的に変更されている可能性があることに注意ください https://github.com/kubernetes-sigs/gateway-api/discussions/2927
Direct Policies Policy を付与したリソースの振る舞いのみを変えるポリシー BackendTLSPolicy • Service リソースを介して Gateway
からバックエンド Pod への 接続の TLS 設定を指定するポリシーリソース • Gateway API 公式で定義されている https://gateway-api.sigs.k8s.io/api-types/backendtlspolicy/
Inherited Policies Policy を付与したリソースだけではなく複数のターゲットリソース全体の 特定の設定の振る舞いを変えるポリシー • Defaults 値は bottom-up
式で、下から上に優先順位がつけられる ◦ Backend にアタッチされた Default が最も優先 • Overrides 値は top-down 式で、上から下に優先順位がつけられる ◦ GatewayClass にアタッチされた Override が最も優先 e.g. GatewayClass, Gateway, HTTPRoute に ポリシーを付与した場合 GatewayClass Override > Gateway Override > HTTPRoute Override > HTTPRoute Default > Gateway Default > GatewayClass Default
Inherited Policies : NGINX Example • 背景 ◦ client_max_body_size
をアプリケーションごとに設定したい ① As a Cluster Operator ほとんどのアプリで機能するように クライアントボディの設定に適切な デフォルト値を設定したい ② As a Application Developer アプリの動作や要求に基づいて クライアントボディの設定を 構成できるようにしたい ③ As a Application Developer クラスタオペレーターによって設定された デフォルトのクライアントボディの 設定を微調整したい ユーザーストーリー
Inherited Policies CRD • targetRef は必ず spec に含める •
defaults, overrides の階層がない policy の場合 default 値とみなす • status は PolicyAncestorStatus の構造を持つべき
Inherited Policies in Practice ① ② ③
User Experience It’s complex とコメントされていた
Example
まとめ・所感 • Gateway API の拡張方法として、Policy Attachment という仕組みが導入されている • Policy
には Direct Policy と Inherited Policiy の2種類が存在 ◦ (所感) Inherited Policy の仕組みは面白いが、やや複雑 • Policy Attachment は現在進行形で Resource 構造や Status の課題など ディスカッションされており、破壊的な変更が入る可能性あり • Policy Attachment の仕組みは今後も発展していきそう ◦ Gateway v1.2 時点で様々な oss が policy を実装している ◦ Gateway v1.3+ 以降で Timeout や Circuit breaking, Auth, CORS など様々な設定を 行うための Policy がリリースできるように Gateway API 公式で議論中