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
Fluentbit_mulitline_filterについて.pdf
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
clouddev-code
June 13, 2024
1k
1
Share
Fluentbit_mulitline_filterについて.pdf
clouddev-code
June 13, 2024
More Decks by clouddev-code
See All by clouddev-code
Amazon_Bedrock_AgentCore_の概要_-_Slidev.pdf
cloudevcode
0
27
Regional_NAT_Gatewayについて_basicとの違い_試した内容スケールアウト_インについて_IPv6_dual_networkでの使い分けなど.pdf
cloudevcode
1
860
Grafana_LokiをECS_Fargateで構築する観点公開版.pdf
cloudevcode
0
31
ADK_for_Java.pdf
cloudevcode
1
86
initContainerをECSで実現したい.pdf
cloudevcode
0
23
VPC_Lattice検討したが_採用しなかった話.pptx.pptx.pdf
cloudevcode
0
21
Presentation_-_コンテナイメージ高速化技術.pptx.pdf
cloudevcode
0
28
GitHub_Copilot_AgentでするMCP_Streamable_HTTPまで.pdf
cloudevcode
0
100
EKS_Auto_Mode_Deep_Live.pdf
cloudevcode
0
48
Featured
See All Featured
Measuring & Analyzing Core Web Vitals
bluesmoon
9
800
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
210
SEO Brein meetup: CTRL+C is not how to scale international SEO
lindahogenes
1
2.5k
brightonSEO & MeasureFest 2025 - Christian Goodrich - Winning strategies for Black Friday CRO & PPC
cargoodrich
3
670
Navigating the moral maze — ethical principles for Al-driven product design
skipperchong
2
320
How STYLIGHT went responsive
nonsquared
100
6k
So, you think you're a good person
axbom
PRO
2
2k
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.6k
Become a Pro
speakerdeck
PRO
31
5.9k
How to Talk to Developers About Accessibility
jct
2
170
Paper Plane (Part 1)
katiecoart
PRO
0
6.4k
Money Talks: Using Revenue to Get Sh*t Done
nikkihalliwell
0
200
Transcript
2024.06.13 JAWS-UG 東京 #12 s.hiruta (@web_se) java, pythonのStackTraceにまたがる場合に有益な Multiline filter
pluginについて
Self introduction 【名前】 s.hiruta ( @web_se ) 【仕事】 コンテナ、マイクロサービス基盤構築 【興味分野】
Containers、WASM+LLM、 Github clouddev-code zenn clouddevcode 2
Previous LT Slide https://speakerdeck.com/cloudevcode 3
セッションの目的 multiline filterの概要、導入注意点 • 導入の背景 • 導入で期待されること • 具体的な使用例 •
4
アジェンダ • Containerログどう収集していますか • ログ収集パターン • メジャーなFluentbitについて深掘り • StackTraceなど複数行にまたがるときの問題点 •
Mulitiline filter • filter設定時の注意点 • Rewrite tag併用時の注意点 • まとめ 5
コンテナログ収集どうしていますか • 6
ECS https://aws.amazon.com/jp/blogs/news/under-the-hood-firelens-for-amazon-ecs-tasks/
8 EKS https://aws.amazon.com/jp/blogs/news/fluent-bit-for-amazon-eks-on-aws-fargate-is-here-jp/
ログ収集パターン • AWSlogs driver • Fluentbit • OpenTlemetry logging 9
AWSlog drvierによるログ収集 • 手軽だけど、Cloudwatch logsからS3にエクスポー トするときは、Amazon Firehoseあるいは、 EventBridgeを利用する必要がある • Cloudwatch
logsのPutLogEventsは高価 10
Fluentbit 11 • super fast, lightweight and high scalable logging
and metrics processor and forwarder https://www.fluentbit.io/
OpenTelmetry logging • OtelでContext Propagationの考え方でメトリクスとトレースと の相関があり、個々の価値向上を図れそう 12 https://opentelemetry.io/docs/specs/otel/logs/
Fluentbitについて深掘り 13
Fluentbitの仕組み 14
Fluentbitの仕組み • 15
Java、PythonなどStackTrace messageのときの問題点 16
Multiline filter • 複数のレコードやログ行に分割されたメッセージを 連結するのに役に立ちます。例としてスタックト レースやログを複数行に分けて出力するアプリ ケーション 17
Multiline filter 18
Multiline filter 19
Multiline filter 20
Rewrite tag 21 • ログレベルの文字列で出力させたい、別の出力先 に出したいときに利用する • Multiline filterと併用する場合、Rewrite Tagで変更
した後のタグが、Multiline の条件に一致しないよ うにする必要がある
Rewrite tag 22
Athena • ログ連結することでAthenaのログフィールドにマー ジさせてクエリすることができる 23
まとめ • 複数行のログメッセージをマージするときに便利 • Rewrite Tagとの併用に気をつける 24
索引 • Multiline – https://docs.fluentbit.io/manual/pipeline/filters/multiline-stacktrace • Fluent Bit の Multiline
Praserを使用して複数行ログを収集する – https://zenn.dev/nh8939/articles/add269d15152ba • Fluent Bit v3.0 Documentation – https://docs.fluentbit.io/manual 25
26 https://github.com/aws-samples/whats-new-summary-notifier AWS What’s new の 情報をクロールし、 Claude 3にまとめを chatに投稿ツール
ツールを改造して、 GoogleChatのスペー スに飛ばすこともで きる おまけ