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
Amazon Aurora DSQLパフォーマンスチェック / Amazon Aurora ...
Search
shiro seike
PRO
February 01, 2025
Programming
0
15
Amazon Aurora DSQLパフォーマンスチェック / Amazon Aurora DSQL Performance Check
#jawsugsaga24 2025年もクラウドでGO!新春LT大会
https://jawsug-saga.connpass.com/event/338826/
shiro seike
PRO
February 01, 2025
Tweet
Share
More Decks by shiro seike
See All by shiro seike
なぜ適用するか、移行して理解するClean Architecture 〜構造を超えて設計を継承する〜 / Why Apply, Migrate and Understand Clean Architecture - Inherit Design Beyond Structure
seike460
PRO
3
790
生成AIコーディングとの向き合い方、AIと共創するという考え方 / How to deal with generative AI coding and the concept of co-creating with AI
seike460
PRO
1
390
地方のPHPerもクラウドを使う理由 ~コストの最適化とチームに向き合う~ / Why even local PHPers use the cloud ~optimize costs and face the team
seike460
PRO
0
64
OpenTelemetryで始めるベンダーフリーなobservability / Vendor-free observability starting with OpenTelemetry
seike460
PRO
0
180
AIコーディングの本質は“コード“ではなく“構造“だった / The essence of AI coding is not “code” but "structure
seike460
PRO
2
1.1k
OpenTelemetryを活用したObservability入門 / Introduction to Observability with OpenTelemetry
seike460
PRO
1
660
Amazon Q Developer Proで効率化するAPI開発入門
seike460
PRO
0
330
実行委員長が振り返るBacklogWorldの裏側と運営Backlog術 / The chairperson of the executive committee looks back on the backstage of BacklogWorld and the art of managing Backlog.
seike460
PRO
0
4
(再)ひとり技術広報からの脱却 / Re:Breaking away from one-man technical public relations
seike460
PRO
1
230
Other Decks in Programming
See All in Programming
フロントエンドのパフォーマンスチューニング
koukimiura
5
2.1k
チームのテスト力を総合的に鍛えて品質、スピード、レジリエンスを共立させる/Testing approach that improves quality, speed, and resilience
goyoki
5
1.2k
新メンバーも今日から大活躍!SREが支えるスケールし続ける組織のオンボーディング
honmarkhunt
5
8.8k
NPOでのDevinの活用
codeforeveryone
0
910
SwiftでMCPサーバーを作ろう!
giginet
PRO
2
110
Android 16KBページサイズ対応をはじめからていねいに
mine2424
0
460
スタートアップの急成長を支えるプラットフォームエンジニアリングと組織戦略
sutochin26
1
7.3k
バイブコーディング超えてバイブデプロイ〜CloudflareMCPで実現する、未来のアプリケーションデリバリー〜
azukiazusa1
2
520
構文解析器入門
ydah
3
760
Python型ヒント完全ガイド 初心者でも分かる、現代的で実践的な使い方
mickey_kubo
1
240
Rails Frontend Evolution: It Was a Setup All Along
skryukov
0
280
A full stack side project webapp all in Kotlin (KotlinConf 2025)
dankim
0
150
Featured
See All Featured
Building Flexible Design Systems
yeseniaperezcruz
328
39k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
21
1.3k
The Cult of Friendly URLs
andyhume
79
6.5k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
357
30k
The Straight Up "How To Draw Better" Workshop
denniskardys
235
140k
Fashionably flexible responsive web design (full day workshop)
malarkey
407
66k
Writing Fast Ruby
sferik
628
62k
Designing for humans not robots
tammielis
253
25k
Stop Working from a Prison Cell
hatefulcrawdad
271
21k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
35
2.4k
RailsConf 2023
tenderlove
30
1.1k
How STYLIGHT went responsive
nonsquared
100
5.6k
Transcript
©Fusic Co., Ltd. 1 Amazon Aurora DSQLΛࢼͯ͠ΈΔ 2025.02.01 @seike460 #jawsugsaga24
2025ΫϥυͰGOʂ৽य़LTେձ
©Fusic Co., Ltd. 2 ਗ਼Ո ࢙ AWS Community Builder Serverless
ίϛϡχςΟ Fukuoka.php Fukuoka.go JAWS-UG Fukuoka Serverless Meetup Fukuoka Cloudflare Meetup Fukuoka JP_Stripes Fukuoka ࣗݾհ ͡Ίʹ גࣜձࣾFusic ϓϦϯγύϧΤϯδχΞ/ΤόϯδΣϦετ
©Fusic Co., Ltd. 3 CONTENTS ࣍ 1. Amazon DSQLͱ 2.
Python͔Βܨ͍ͰΈΔ 3. ఏڙϦʔδϣϯͷ՝ 4. ·ͱΊ
©Fusic Co., Ltd. 4 Amazon DSQLͱ 1
©Fusic Co., Ltd. 5 Amazon DSQLͱ Amazon Aurora DSQLʢDistributed SQLʣAuroraͷ৽ػೳͰ͋Γɺ
ҎԼͷಛΛ࣋ͪ·͢ - ࢄSQLΞʔΩςΫνϟ - ΫϥελશମͰΫΤϦΛฒྻॲཧ͠ɺߴ͍εέʔϥϏϦςΟΛ࣮ݱ - άϩʔόϧͳσʔλҰ؏ੑ - ෳͷϦʔδϣϯʹ·͕ͨΔσʔλϕʔεͰ Ұ؏ͨ͠τϥϯβΫγϣϯΛఏڙ - PostgreSQLޓ - PostgreSQLͱͷޓੑΛ࣋ͪͭͭɺ ߴͳੳΫΤϦͱεϧʔϓοτΛఏڙ
©Fusic Co., Ltd. 6 2 Python͔Βܨ͍ͰΈΔ
©Fusic Co., Ltd. 7 Amazon DSQLͷ࡞͔ΜͨΜ Create clusterΛԡԼ
©Fusic Co., Ltd. 8 Amazon DSQLͷ࡞͔ΜͨΜ NameλάΛઃఆͰ͖ΔͷͰ໊લΛઃఆ͢Δ ϚϧνϦʔδϣϯʹ͍ͨ͠߹ Add linked
RegionsʹνΣοΫΛ͢Δ
©Fusic Co., Ltd. 9 Amazon DSQLͷ࡞͔ΜͨΜ ଓใৄࡉ͔ΒConnectΛԡ͢ͱͰ͖ͯ·͢
©Fusic Co., Ltd. 10 Python͔Βͷଓ ιʔείʔυΫϥεϝιου༷ͷͷΛྲྀ༻͖ͤͯ͞·ͨ͠ɻ ࢀߟURLɿhttps://dev.classmethod.jp/articles/connect-aurora-dsql-from-aws-cli-and-python-psycopg-on-aws-cloudshell/
©Fusic Co., Ltd. 11 InsertͱSelectΛ10ճ܁Γฦ͢ʢσϞʣ ͓ੈࣙʹૣ͍ͱݴ͑ͳ͍
©Fusic Co., Ltd. 12 ఏڙϦʔδϣϯͷ՝ 3
©Fusic Co., Ltd. 13 Amazon DSQLͷ՝ όʔδχΞ෦ʢus-east-1ʣͱΦϋΠΦʢus-east-2ʣͰ͔͠ར༻Ͱ͖ͳ͍ ͦͦ·ͩϓϨϏϡʔͳͷͰ͠ΐ͏͕ͳ͍ͷͰ͕͢ɺ ଠฏ༸ΛڬΜͰSQL͕ྲྀΕΔͷඇৗʹݫͦ͠͏
©Fusic Co., Ltd. 14 LambdaΛόʔδχΞ෦ʹཱͯΔʁ౦ژʹཱͯΔʁ ͦΕͰར༻͍ͨ͠߹ɺ AWS LambdaͱDSQLͷڑΛߟྀ͠όʔδχΞ෦ʹཱͯΔ͖ͳͷ͔ ͦΕͱAWS LambdaͷىಈΛ༏ઌͯ͠౦ژʹཱͯΔ͖ͳͷ͔
©Fusic Co., Ltd. 15 ࢼͯ͠ΈΑ͏ ͬ͞ͱAWS LambdaͰࢼͯ͠ΈΑ͏ͱಉ͡ιʔείʔυͰ ࢼͨ͠ͱ͜ΖΤϥʔ͕ൃੜɺIPv6ͷIPʹଓͰ͖ͯͳ͍Έ͍ͨ VPC Lambdaʹઃఆͯ͠IPv6ʹઃఆ͠ͳ͚ΕͳΒͳ͍
©Fusic Co., Ltd. 16 VPC LambdaΛ࡞ͯ͠IPv6ରԠͯ͠ࢼͯ͠ΈΔ VPC Lambda ʹରԠͯ͠IPv̒༗ޮԽͯ͠Έͯ͏·͍͔͘ͳ͍ connection
is bad: no error details available ʢଓෆྑɿΤϥʔͷৄࡉෆ໌ʣ ͦͷޙɺॾʑࢼ͍ͯͨ͠ͱ͜ΖɺIPv4ͷϩάग़ݱ࢝͠ΊΔ…
©Fusic Co., Ltd. 17 Γ͍ͨ͜ͱAmazon Aurora DSQLͷύϑΥʔϚϯε ʢ࠶ʣख๏Ϋϥεϝιου༷ͷͷΛྲྀ༻͖ͤͯ͞·ͨ͠ɻ ࢀߟURLɿhttps://dev.classmethod.jp/articles/connect-aurora-dsql-from-aws-cli-and-python-psycopg-on-aws-cloudshell/
©Fusic Co., Ltd. 18 InsertͱSelectΛ10ճ܁Γฦ͢ʢσϞʣ 1/40 ʙ 1/100·ͰߴԽͨ͠ͷͰɺྲྀੴʹڑͷࠩେ͖͍
©Fusic Co., Ltd. 19 ·ͱΊ 4
©Fusic Co., Ltd. 20 ·ͱΊ Amazon Aurora DSQLࢄSQLΞʔΩςΫνϟɺαʔόϨεͱͯ͠৺ͪʹͯͨ͠αʔϏε Point 01
ͪΖΜػೳ੍ݶͳͲ͋Δ͚Ͳɺ͑ͳ͍Θ͚Ͱͳ͍ Point 02 IPv6ରԠ͠ͳ͍ͱ͍͚ͳ͍ʁ -> ͭ·ΓVPC LambdaͰͳ͍ͱ͍͚ͳ͍ʁʢະ֬ఆʣ Point 03 ΓόʔδχΞ෦ͷํ͕രͰૣ͍ɺϓϨϏϡʔ֎Εͯૣ͘ຊϦʔδϣϯʹདྷͯཉ͍͠ʂ Point 04
©Fusic Co., Ltd. 21 Thank You We are Hiring! https://recruit.fusic.co.jp/
͝ਗ਼ௌ͍͖ͨͩ͋Γ͕ͱ͏͍͟͝·ͨ͠