Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
AWS初心者が苦労してCDKカスタムリソースを作った話 / AWS beginners str...
Search
yayoi_dd
March 28, 2024
Technology
1
2.8k
AWS初心者が苦労してCDKカスタムリソースを作った話 / AWS beginners struggled to create CDK custom resources
弥生株式会社 もくテク
インフラ構築、どうしてる? ~IaCの知見共有会~(2024/03/28)
https://mokuteku.connpass.com/event/311038/
yayoi_dd
March 28, 2024
Tweet
Share
More Decks by yayoi_dd
See All by yayoi_dd
“お客さま視点”を手に入れろ!! / Get the Customer’s Perspective!!
yayoi_dd
0
100
プロジェクト改善、まずは“ネタ出しの文化”から / Improving Projects Starts with a Culture of Idea Generation
yayoi_dd
0
100
使いにくい仕様を改善した件 / How We Improved a Difficult-to-Use Feature
yayoi_dd
0
110
弥生のQAエンジニア 品質保証活動と今後の課題 / Yayoi QA engineers, Quality assurance activities and future challenges
yayoi_dd
0
150
【弥生】20250130_AWSマルチアカウント運用セミナー登壇資料
yayoi_dd
2
5k
Amazon OpenSearchのコスト最適化とZeroETLへの期待 / Amazon OpenSearch Cost Optimization and ZeroETL Expectations
yayoi_dd
1
160
フロントエンドとバックエンド非同期連携パターンのセッションを見てきた話 / Talk about seeing a session on front-end and back-end asynchronous coordination patterns
yayoi_dd
0
100
reInventで学んだWebシステム運用のBadDayへの備え方 / How to Prepare for BadDay in Web System Operations Learned at reInvent
yayoi_dd
0
77
AWS reInventで感じた世界に見る生成AIの競争 / Competition in Generative AI as Seen Around the World at AWS reInvent
yayoi_dd
0
81
Other Decks in Technology
See All in Technology
それでも私が品質保証プロセスを作り続ける理由 #テストラジオ / Why I still continue to create QA process
pineapplecandy
0
170
物体検出モデルでシイタケの収穫時期を自動判定してみた。 #devio2025
lamaglama39
0
280
Building a cloud native business on open source
lizrice
0
170
QA業務を変える(!?)AIを併用した不具合分析の実践
ma2ri
0
120
「魔法少女まどか☆マギカ Magia Exedra」におけるバックエンドの技術選定
gree_tech
PRO
0
120
serverless team topology
_kensh
3
190
OCIjp_Oracle AI World_Recap
shinpy
1
170
Wasmの気になる最新情報
askua
0
180
AWS DMS で SQL Server を移行してみた/aws-dms-sql-server-migration
emiki
0
120
Dylib Hijacking on macOS: Dead or Alive?
patrickwardle
0
450
Sansan Engineering Unit 紹介資料
sansan33
PRO
1
3k
ソフトウェアエンジニアの生成AI活用と、これから
lycorptech_jp
PRO
0
850
Featured
See All Featured
4 Signs Your Business is Dying
shpigford
185
22k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
22k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4k
Gamification - CAS2011
davidbonilla
81
5.5k
The Cult of Friendly URLs
andyhume
79
6.6k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
9
930
YesSQL, Process and Tooling at Scale
rocio
173
15k
How GitHub (no longer) Works
holman
315
140k
Practical Orchestrator
shlominoach
190
11k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.6k
Making the Leap to Tech Lead
cromwellryan
135
9.6k
Designing for Performance
lara
610
69k
Transcript
AWS初心者が苦労して CDKカスタムリソース を作った話 弥生株式会社 岩佐
自己紹介 ▪ 岩佐 祐樹 ▪ 2021年1月1日中途入社 ▪ 会計Nextサブシステム開発チーム所属 ▪ 2023年6月頃からAWS、CDKを使い始める
カスタムリソースとは ▪ CloudFormationで非対応のリソースを作ることができる仕組み – CloudFormationでもできるしCDKでもできる ▪ 作られる実体はLambda Function – LambdaがAWS
SDKを実行して、リソースが作成される ▪ CDKが補完してくれている部分も自力で書く必要がある
作ったもの(一部) ▪ ECS(Fargate)の AutoScaling設定を作った ▪ MetricMathを使用して、 SQSキューに溜まった メッセージ数÷タスク数 =1タスク当たりの処理 可能件数になるように
ターゲット追跡でスケー リングする設定 ▪ 2023/12の時点でCLIでの 設定しか対応していな かった
良かったこと ▪ 環境差異やミスを無くせた – 手作業(しかもCLI)で設定しなければいけないものがコードで管理できる ようになった – 他のリソースと同じタイミングで作成できるようになった ▪ CDKのありがたみがわかった
– CDKが補完してくれている部分も気にする必要がある ▪ AWS SDKに少しだけ詳しくなった
悪かったこと ▪ 可読性が低くてメンテナンスしづらい ▪ カスタムリソースで作成したAWSリソースへのタグ付けは また別のカスタムリソースが必要になった ▪ 初心者には難しく、使いこなせていない – CDKが補完してくれていたところが多かった(のだろうという推測)
– AWS SDKで設定できることが多すぎて何が必要で何が不要かわからない
まとめ ▪ カスタムリソースを使うとCloudFormation非対応のリソースも コードで管理できる ▪ 保守性が低いので使いどころは考えたほうがいい ▪ 初心者にとっては良いことも悪いことも多い