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
Datadog Logsで実現するオブザーバビリティの向上 / Enhancing Obser...
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Akira Kuriyama
April 24, 2025
Technology
210
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Datadog Logsで実現するオブザーバビリティの向上 / Enhancing Observability with Datadog Logs
Akira Kuriyama
April 24, 2025
More Decks by Akira Kuriyama
See All by Akira Kuriyama
ゼロから始める全社横断プロダクトセキュリティ / Building Organization-Wide Product Security
sheepland
0
170
Datadog On-Calを本番導入しました / Datadog On-Cal now in production
sheepland
0
620
コンテナ脆弱性修正をRenovate,Dependabotのように行う / Fix Container vulnerabilities on CICD
sheepland
2
530
Docker Build Cloudを導入してコンテナイメージビルド時間を80%削減した話 / Speeding Up Container Builds with Docker Build Cloud
sheepland
0
220
Design Doc のすすめ / The Importance of Design Docs
sheepland
0
1.3k
Datadogのグラフにデプロイタイミングを表示する / deploy timing on datadog graph
sheepland
1
790
英語学習の始め方 / How to start learning English
sheepland
0
130
Other Decks in Technology
See All in Technology
小さく始める AI 活用推進 ― 日経電子版 Web チームの事例/nikkei-tech-talk47
nikkei_engineer_recruiting
0
270
エンジニアリング戦略の作り方 / Crafting Engineering Strategy
iwashi86
21
6.9k
エラーバジェットのアラートのタイミングを考える.pdf
kairim0
0
150
Bucharest Tech Week 2026 - Reinventing testing practices in the AI era
edeandrea
PRO
1
160
脆弱性対応、どこで線を引くか
rymiyamoto
1
390
Disciplined Vibes: Scaling AI-Assisted Engineering
sheharyar
0
140
AI駆動開発を通して感じた、 AI時代のデザイナーの役割変化
whisaiyo
3
2.1k
2026 TECHFRESH 畢業分享會 - 開發日常大解密!從領域驅動到企業級上線
line_developers_tw
PRO
0
1k
【Cyber-sec+】経営層を"動かす"ための考え方
hssh2_bin
0
190
2026TECHFRESH畢業分享會 - 原生還是跨平台? App 開發踩坑實錄
line_developers_tw
PRO
0
1k
Chainlitで作るお手軽チャットUI
ynt0485
0
240
AIソロプレナー時代に2ヶ月で20人増員した事業創造会社の開発組織の話
miyatakoji
0
660
Featured
See All Featured
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
1
350
sira's awesome portfolio website redesign presentation
elsirapls
0
280
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.2k
Digital Projects Gone Horribly Wrong (And the UX Pros Who Still Save the Day) - Dean Schuster
uxyall
1
1.7k
技術選定の審美眼(2025年版) / Understanding the Spiral of Technologies 2025 edition
twada
PRO
118
120k
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
5
1.1k
Money Talks: Using Revenue to Get Sh*t Done
nikkihalliwell
0
250
Deep Space Network (abreviated)
tonyrice
0
170
AI in Enterprises - Java and Open Source to the Rescue
ivargrimstad
0
1.3k
Discover your Explorer Soul
emna__ayadi
2
1.1k
Designing Experiences People Love
moore
143
24k
A better future with KSS
kneath
240
18k
Transcript
Confidential Datadog Logsで実現する オブザーバビリティの向上 @yabaibuki.dev#5
Copyright Hacobu, Inc. 2 自己紹介 栗山 聖 (@sheepland) 所属 株式会社Hacobu
プラットフォームチーム 仕事 プラットフォームエンジニアリング&SRE 趣味 漫画、SF小説、映画
Copyright Hacobu, Inc. 3 Metrics Logs Traces • Hacobuが収集しているログの種類 •
ログ収集方法 本日の内容
Copyright Hacobu, Inc. 4 ログ基盤には Datadog Logs を使用 各種ログをDatadogに集約 🐕
Copyright Hacobu, Inc. 5 収集しているログの紹介
Copyright Hacobu, Inc. 6 バックエンドアプリケーションログ ログがDatadog APMと紐付いている🤝 • APMのリクエストからそのリクエストが出力したログ を見れる
• またログからAPMのリクエストも辿れる
Copyright Hacobu, Inc. 7 バックエンドアプリケーションログ ちなみに、弊社はマルチプロダクト展開してるので プロダクト間通信がある そのためTrace IDの伝播が必要 プラットフォームチーム作成の共通ライブラリにより
プロダクト側で意識せずトレーシング可能
Copyright Hacobu, Inc. 8 フロントエンドログ ログがDatadog RUM(Real User Monitoring)と紐付い ている🤝
ログからユーザ操作履歴が確認できる
Copyright Hacobu, Inc. 9 スロークエリログ DB負荷やレスポンス遅延は大抵スロークエリが原因😥 スロークエリを Datadog Logs に送信
Copyright Hacobu, Inc. 10 スロークエリログ ⚔送信方法 Datadog Forwarder (AWS Lambda)
を使用 CloudWatch Logs → Forwarder → Datadog Logs Datadog Serverless Functions https://github.com/DataDog/datadog-serverless-functions の/aws/logs_monitoring
Copyright Hacobu, Inc. 11 スロークエリログ スロークエリログは構造化ログではない Datadog Logs のPipelineのGrok Parserで以下のような正規表現を定義し、
構造化データに変換している💪 これにより、スロークエリログ内のtimestamp, queryTime, queryなどの情報 をAttributeとして登録される rds_slowquery ^\# Time: %{date("yyyy-MM-dd'T'HH:mm:ss.SSSSSSZ"):date}\n+\# User@Host: %{notSpace: user} @ \[%{ip: host}\] Id:[\x20\t]+%{number: id}\n+\# Query_time: %{number: queryTime} Lock_time: %{number: lockTime} Rows_sent: %{number: rowsSent} Rows_examined: %{number: rowsExamined}\n+ *SET timestamp=%{number: timestamp};\n+%{regex("[a-zA-Z].*"):query}.
Copyright Hacobu, Inc. 12 Lambdaログ CloudWatch Logsでの検索は大変。LambdaログもDatadogに送信 ただし料金対策のために 「実行頻度が低いLambdaに絞る」「エラーログのみ送信」などをしている 先ほどのDatadog
Forwarderを使って送信 → 最近は Datadog Lambda Extension を使うことが推奨
Copyright Hacobu, Inc. 13 ログ料金の下げるために、Datadog Logsの除外フィル ターで不要なログを保存しないように頑張っている
Copyright Hacobu, Inc. 14 まとめ • オブザーバビリティツールとログ基盤の統合をすると 調査がしやすい✨ • 特にスロークエリログを送るのはオススメ👈
Copyright Hacobu, Inc. 15 採用情報 Hacobuではエンジニアを積極採用中です! https://career.hacobu.jp/