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
Distributed Tracing with OpenCensus at Wantedly...
Search
Yuichi Saito
April 03, 2019
Technology
3
5.2k
Distributed Tracing with OpenCensus at Wantedly, Inc.
OpenCensus meetup vol.1
https://opencensus.connpass.com/event/123885/
Yuichi Saito
April 03, 2019
Tweet
Share
More Decks by Yuichi Saito
See All by Yuichi Saito
失敗から学ぶ - ポストモーテム / Postmotem culture at Wantedly
munisystem
3
38k
OpenCensus による APM の実現と、未来 / Implementing APM with OpenCensus
munisystem
8
7.1k
Effective Health Checking
munisystem
2
790
Learn more about Admission Webhooks
munisystem
1
1.8k
An introduction to monitoring Go Application with OpenCensus
munisystem
1
1.3k
Dgraph - A high performance graph database written in pure Go
munisystem
7
7.5k
Other Decks in Technology
See All in Technology
ゆるふわエンジニアでもAIフローにチャレンジしたい!!~Zapierのすゝめ~
masakiokuda
2
100
Android Studio の 新しいAI機能を試してみよう / Try out the new AI features in Android Studio
yanzm
0
280
kintone開発チームの紹介
cybozuinsideout
PRO
0
73k
モバイルアプリ研修
recruitengineers
PRO
4
520
制約理論(ToC)入門
recruitengineers
PRO
5
1k
Evolution on AI Agent and Beyond - AGI への道のりと、シンギュラリティの3つのシナリオ
masayamoriofficial
0
190
つくって納得、つかって実感! 大規模言語モデルことはじめ
recruitengineers
PRO
25
6.8k
ドキュメントはAIの味方!スタートアップのアジャイルを加速するADR
kawauso
3
410
人を動かすことについて考える
ichimichi
2
330
実践AIガバナンス
asei
2
110
Yahoo!広告ビジネス基盤におけるバックエンド開発
lycorptech_jp
PRO
1
280
モダンフロントエンド 開発研修
recruitengineers
PRO
4
1.1k
Featured
See All Featured
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
Designing for Performance
lara
610
69k
Documentation Writing (for coders)
carmenintech
73
5k
GraphQLとの向き合い方2022年版
quramy
49
14k
The Cult of Friendly URLs
andyhume
79
6.6k
Testing 201, or: Great Expectations
jmmastey
45
7.6k
YesSQL, Process and Tooling at Scale
rocio
173
14k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
10
1k
A designer walks into a library…
pauljervisheath
207
24k
Building Adaptive Systems
keathley
43
2.7k
The Power of CSS Pseudo Elements
geoffreycrofte
77
5.9k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
667
120k
Transcript
©2018 Wantedly, Inc. Distributed Tracing with OpenCensus at Wantedly, Inc.
OpenCensus meetup vol.1 03.Apr.2019 - @munisystem
©2018 Wantedly, Inc. 0QFO$FOTVTͷಋೖഎܠ 8BOUFEMZ *ODʹ͓͚ΔࢄτϨʔγϯά ݱঢ়ͷ՝
·ͱΊ Agenda
©2018 Wantedly, Inc. !NVOJTZTUFN:VJDIJ4BJUP *OGSBTUSVDUVSF5FBNBU8BOUFEMZ *OD
©2018 Wantedly, Inc. 0QFO$FOTVTͷಋೖഎܠ
©2018 Wantedly, Inc. 8BOUFEMZʹ͓͚Δ.JDSPTFSWJDFTͷݱঢ় w 1PMZHMPU w 3VCZͱ(P͕ϝΠϯ w αʔϏεͷυϝΠϯʹΑͬͯ1ZUIPO/PEFɺ3VTU࠾༻
w .VMUJ$MPVE w "84 ,VCFSOFUFTPO&$ 3%4 &MBTUJDBDIF ʜ w ($1 #JH2VFSZ $MPVE%BUBTUPSF $MPVE1VC4VC ʜ
©2018 Wantedly, Inc. ͳͥ.JDSPTFSWJDFTΛ࠾༻ͨ͠ͷ͔ ͷ8BOUFEMZ1FPQMFͷ։ൃ͔Β.JDSPTFSWJDFTΛ࠾༻ w ࣌ϞϊϦγοΫͳ3BJMTΞϓϦέʔγϣϯ͕ݸଘࡏ w αʔϏεͷಛੑ্ɺ3BJMTͰ࣮ݱ͠ʹ͍͘ػೳΛ࣮ݱ͢Δඞཁ͕͋ͬͨ w
ฒྻԽɺػցֶश w ߴͳ։ൃͱϦϦʔεͷཁٻ w ϦϦʔεαΠΫϧͷ
©2018 Wantedly, Inc. ύϑΥʔϚϯεܭଌͷ͠͞ w 8BOUFEMZͰ"1.ͷج൫ͱͯ͠/FX3FMJDΛ࠾༻͍ͯͨ͠
©2018 Wantedly, Inc. ύϑΥʔϚϯεܭଌͷ͠͞ w 8BOUFEMZͰ"1.ͷج൫ͱͯ͠/FX3FMJDΛ࠾༻͍ͯͨ͠ w SVOUJNFϨϕϧͰͷϝτϦΫεͷऩू w -BUFODZ
4UBDLUSBDF ($IFBQTJ[F ʜ w .JDSPTFSWJDFTͰαʔϏεؒͷσʔλͷΓऔΓ͕ωοτϫʔΫӽ͠ʹߦΘΕΔ w ϦΫΤετઌͰͲΜͳॲཧ͕ߦΘΕ͍ͯΔͷ͔ΛஅͰ͖ͳ͍
©2018 Wantedly, Inc. ύϑΥʔϚϯεܭଌͷ͠͞ Receive A /api/products/1 timeline DB Access
Request B /api/reviews/1 #Ͱͳʹ͕ߦΘΕ͍ͯΔͷ͔"ͷ4UBDL5SBDF্͔ΒஅͰ͖ͳ͍
©2018 Wantedly, Inc. ύϑΥʔϚϯεܭଌͷ͠͞ w 8BOUFEMZͰ"1.ͷج൫ͱͯ͠/FX3FMJDΛ࠾༻͍ͯͨ͠ w SVOUJNFϨϕϧͰͷϝτϦΫεͷऩू w -BUFODZ
4UBDLUSBDF ($IFBQTJ[F ʜ w .JDSPTFSWJDFTͰαʔϏεؒͷσʔλͷΓऔΓ͕ωοτϫʔΫӽ͠ʹߦΘΕΔ w ϦΫΤετઌͰͲΜͳॲཧ͕ߦΘΕ͍ͯΔͷ͔ΛஅͰ͖ͳ͍ ࢄτϨʔγϯάͷಋೖ
©2018 Wantedly, Inc. ࢄτϨʔγϯά
©2018 Wantedly, Inc. ࢄτϨʔγϯάಋೖͷΞϓϩʔν ͬ͘͟Γಋೖํ๏௨ΓʹྨͰ͖Δ w ϕϯμʔ͕ఏڙ͢Δ-JCSBSZͷར༻ͱ࣮ʢྫ"NB[PO93BZ w 0QFO$FOTVT0QFO5SBDJOHʹද͢Δڞ௨Խ࣮
©2018 Wantedly, Inc. ٕज़બΛ͢Δͱ͖ʹߟ͑ͨ͜ͱ w όοΫΤϯυͷมߋ༰қੑͷ୲อ w ܗ͞ΕͨΤίγεςϜͷར༻͕Մೳ w 1PMZHMPUͳڥͰ͋Δ͜ͱΛҙࣝ͢Δͱɺ
গ͠ͰΤίγεςϜʹΕΔܗʹ͍ͨ͠ ڞ௨ԽϑϨʔϜϫʔΫͷ࠾༻
©2018 Wantedly, Inc. Կނ0QFO$FOTVTΛ࠾༻ͨ͠ͷ͔ w ͲͪΒ࣮ΛϕϯμʔΛ͢Δͱ͍͏తҰॹ w ࢄτϨʔγϯάҎ֎ͷར༻ՁΛߟ͑ͨ w 0QFO5SBDJOHࢄτϨʔγϯά͚ͩͰ͋Δͷʹର͠ɺ
0QFO$FOTVT0CTFSWBCJMJUZશൠʹϑΥʔΧε͍ͯ͠Δ w ΞϓϦέʔγϣϯͷϝτϦΫεͷऩूΛݟਾ͑ͨ w ΤίγεςϜͷͷݟࠐΈ w (PPHMF4UBDLESJWFSͰ0QFO$FOTVTͷར༻Λਪ͍ͯͨ͠
©2018 Wantedly, Inc. 8BOUFEMZ *ODʹ͓͚ΔࢄτϨʔγϯά
©2018 Wantedly, Inc. ࢄτϨʔγϯάͷόοΫΤϯυ w όοΫΤϯυʹ%BUBEPH"1.ͱ4UBDLESJWFS5SBDFΛ࠾༻ w %BUBEPH"1.͕ϝΠϯ w ͱͱ%BUBEPHΛར༻͍ͯͨ͠ͱ͍͏എܠ
w %BUBEPH"1.Ͱಛఆͷڥ͚ͩͯ͢ͷ5SBDFΛ͢ࣄ͕Ͱ͖ͳ͍ w ͜ΕΛ୲อ͢ΔͨΊʹ4UBDLESJWFS5SBDFͱซ༻͍ͯ͠Δ w কདྷతʹόοΫΤϯυΛ౷Ұͤ͞Δ
©2018 Wantedly, Inc. 4IBSFE-JCSBSZʹΑΔڞ௨Խ w ࣾʹϚΠΫϩαʔϏεʹඞཁͳϩδοΫΛ֤αʔϏεʹఏڙ͢ΔͨΊͷ ڞ௨Խ࣮͕ଘࡏ͍ͯͨ͠ w 5JNFPVU3FUSZ"VUIFOUJDBUPO-PHHJOH w
ࢄτϨʔγϯάͷ࣮͜Εʹแ͍ͤͯ͞Δ w 3VCZͱ(PͷΈͰఏڙ w 1ZUIPOͦͷଞͷݴޠϦΫΤετͷͰར༻͞ΕΔέʔε͕ଟ͍ w ߋʹ%#ͷSFBEXSJUF΄΅ແ͍ w VQTUSFBNͷϦΫΤετͷ4QBO͚ͩͰ͋Δఔஅ͕Մೳ
©2018 Wantedly, Inc. ར༻͍ͯ͠Δ-JCSBSZ w (Pʹؔͯ͠ެࣜͷͷΛར༻ w 3VCZGPSL IUUQTHJUIVCDPNXBOUFEMZPQFODFOTVTSVCZ Λར༻
w ࣌UPQMFWFMͷ4QBO͕ࢠ4QBOʹൖ͞Εͳ͍ͱ͍͏க໋తͳόά͕͋ͬͨ w 13Λૹ͕ͬͨɺϝϯςφෆࡏͰϦϦʔε͞Εͳ͍࠷ۙϚʔδ͞Εͨ w UPQMFWFM4QBOʹ"UUSJCVUFΛࠩ͠ࠐΉͨΊͷIPPLΛࣗ࡞͍ͯͯ͠ɺ ͦΕ͕·ͩຊମʹ13Λग़͍ͯ͠ͳ͍ w %BUBEPHͷ&YQPSUFSʹؔͯࣗ͠࡞ w IUUQTHJUIVCDPNNVOJTZTUFNPQFODFOTVTEBUBEPH
©2018 Wantedly, Inc. ϝλσʔλͷૠೖ w ݕࡧͷͨΊʹϝλσʔλ w ,VCFSOFUFTNFUBEBUB w 3FRVFTU*%
w 6TFS*% w %BUBEPH"1.ͷ࠷దԽͷͨΊͷϝλσʔλ
©2018 Wantedly, Inc. 3FRVFTU*%ͷൖ w 3FRVFTU*%ผαʔϏεʹൖ͍ͯ͠Δ w "DDFTT-PHHJOH w &SSPSUSBDLFS
)POFZCBEHFS
©2018 Wantedly, Inc. )551)FBEFS1SPQBHBUJPO w 5SBDF$POUFYUQSPQBHBUJPOGPSNBUΛ࠾༻ w 0QFO$FOTVTͷ༷Ͱ5SBDF$POUFYUͷؚ࣮͕·Ε͍ͯΔ w PQFODFOTVTSVCZ#͕·࣮ͩ͞Ε͍ͯͳ͍
©2018 Wantedly, Inc. 4BNQMJOH w ։ൃڥͯ͢ͷϦΫΤετͷॲཧΛτϨʔεͰ͖ΔΑ͏ʹɺ αϯϓϦϯάߦ͍ͬͯͳ͍ w 1SPEVDUJPOڥαʔϏεΤϯυϙΠϯτʹؔΘΒͣҰˋͰઃఆ w
ϦΫΤετ4QBOͷ͕ଟ͍ͨΊ w ΞϓϦέʔγϣϯଆͷQFSGPSNBODFJTTVF w όοΫΤϯυͷQSJDJOH
©2018 Wantedly, Inc. ($1Ͱͷར༻ w 4%,ଆͰ0QFO$FOTVT͕ରԠ͞Ε͍ͯΔ w ಛʹͳʹͤͣFDPTZTUFNʹΕΔ
©2018 Wantedly, Inc. ݱঢ়ͷ՝
©2018 Wantedly, Inc. όοΫΤϯυݻ༗ͷ࠷దԽͷ࣮ݱ w ༩͞Ε͍ͯΔ"UUSJCVUFʹΑͬͯόοΫΤϯυͷৼΔ͍͕มΘΔ w %BUBEPH"1.ͰTQBOUZQFͷͰαʔϏεͷΧςΰϥΠζ͕มΘΔ w UPQMFWFMͷ4QBOͰղܾ͢ΔͷͳΒ·͍͍ͩ
w SFEJTDMJFOUʹಛఆͷ"UUSJCVUFΛࠩ͠ࠐΉʹͲ͏͢Δ w SFEJTDMJFOUଆͰIPPLΛ༻ҙ͢Δ w NPOLFZQBUDIΛ͋ͯΔ
©2018 Wantedly, Inc. ΞϓϦέʔγϣϯίʔυͱϕϯμʔͷશͳ w &YQPSUFSίʔυʹґଘ w ϥΠϒϥϦͷΞοϓσʔτͷ͠͞ w 1PMZHMPUͱ&YQPSUFS࣮
w ओཁͳݴޠ͚࣮ͩ͢Δͷݱ࣮తͰͳ͍ w &YQPSUFSͷࣗ࡞ͱ͍͏બࢶ w ϕϯμʔଆͷػೳͷैͷίετ
©2018 Wantedly, Inc. 0QFO$FOTVT4FSWJDF https://github.com/census-instrumentation/opencensus-service/blob/master/images/opencensus-service-deployment-models.png
©2018 Wantedly, Inc. 0QFO$FOTVT4FSWJDF w ϕϯμʔͱΞϓϦέʔγϣϯͷશͳͷ࣮ݱ w "HFOUʜ5SBDF4UBUTͷऩूɺ$PMMFDUPSͷू w $PMMFDUPSʜҙͷόοΫΤϯυʹूͨ͠5SBDF4UBUTΛૹ৴
w ར w TBNQMJOHTUSBUFHZͷมߋϝλσʔλͷ༩Λ$PMMFDUPSଆͰ࣮ݱ w ϕϯμʔ(Pͷ࣮͚ͩ༻ҙ͢Εྑ͍
©2018 Wantedly, Inc. ·ͱΊ w 0QFO$FOTVTΛࢄτϨʔγϯάͰར༻͢ΔϝϦοτ w ϕϯμʔͱίʔυͷͷ࣮ݱ w ϩάϝτϦΫεͷऩूͷ֦ுੑ
w ΤίγεςϜͷେ͖͞ w 8BOUFEMZ *ODʹ͓͚ΔࢄτϨʔγϯά w 4IBSFE-JCSBSZʹΑΔ࣮ͷڞ௨Խ w ݕࡧͷͨΊͷϝλσʔλͷૹ৴