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
Mackerel and Stripe / Qiita x Stripe Meetup
Search
astj
PRO
April 12, 2019
Technology
0
5.3k
Mackerel and Stripe / Qiita x Stripe Meetup
https://connpass.com/event/123900/
astj
PRO
April 12, 2019
Tweet
Share
More Decks by astj
See All by astj
Mackerel の時系列データベースにおける Redis Cluster の利用と Amazon ElastiCache への移行について / AWS Purpose-Built Databases Week
astj
PRO
3
5.5k
Mackerel のコンテナ監視の近況 / Mackerel Meetup #13
astj
PRO
1
2.1k
Observability: Mackerel による観測と Mackerel の観測 / NoOps Meetup Tokyo #8
astj
PRO
2
1.9k
サービス開発と健全なプロダクトメンテナンスを開発チームで持続的に取り組む / Developers Boost KANSAI
astj
PRO
1
1.3k
Mackerel をオンプレミスから AWS に移してからの1年半を振り返る / Hatena Engineer Seminar #11
astj
PRO
0
1k
AWS で実現した Mackerel 時系列データ1分粒度長期保存の裏側 / Mackerel Meetup #11 Tokyo
astj
PRO
6
29k
稼働中の Web サービスの perl のバージョンを上げていく
astj
PRO
0
7.2k
Perl 6 で Web Application Framework をつくる
astj
PRO
0
4.4k
Other Decks in Technology
See All in Technology
Lambdaと地方とコミュニティ
miu_crescent
2
370
The Rise of LLMOps
asei
7
1.4k
B2B SaaSから見た最近のC#/.NETの進化
sansantech
PRO
0
770
データプロダクトの定義からはじめる、データコントラクト駆動なデータ基盤
chanyou0311
2
310
ExaDB-D dbaascli で出来ること
oracle4engineer
PRO
0
3.8k
AGIについてChatGPTに聞いてみた
blueb
0
130
EventHub Startup CTO of the year 2024 ピッチ資料
eventhub
0
110
IBC 2024 動画技術関連レポート / IBC 2024 Report
cyberagentdevelopers
PRO
0
110
Why does continuous profiling matter to developers? #appdevelopercon
salaboy
0
190
rootlessコンテナのすゝめ - 研究室サーバーでもできる安全なコンテナ管理
kitsuya0828
3
380
[CV勉強会@関東 ECCV2024 読み会] オンラインマッピング x トラッキング MapTracker: Tracking with Strided Memory Fusion for Consistent Vector HD Mapping (Chen+, ECCV24)
abemii
0
220
サイバーセキュリティと認知バイアス:対策の隙を埋める心理学的アプローチ
shumei_ito
0
380
Featured
See All Featured
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9.1k
VelocityConf: Rendering Performance Case Studies
addyosmani
325
24k
A better future with KSS
kneath
238
17k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
44
2.2k
RailsConf 2023
tenderlove
29
900
Fontdeck: Realign not Redesign
paulrobertlloyd
82
5.2k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
31
2.7k
Automating Front-end Workflow
addyosmani
1366
200k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
25
1.8k
Building Applications with DynamoDB
mza
90
6.1k
Speed Design
sergeychernyshev
25
620
Writing Fast Ruby
sferik
627
61k
Transcript
Mackerel and Stripe 2019/04/12 Qiita x Stripe Meetup Asato WAKISAKA
(Hatena)
Asato WAKISAKA (GitHub: @astj) ͯͳ ΞϓϦέʔγϣϯΤϯδχΞ Mackerel ։ൃνʔϜ (2016/08~) Mackerel
ςοΫϦʔυ (2018/05~)
Mackerel
None
None
None
None
• 2014ϦϦʔεͷʮαʔόʔࢹαʔϏεʯ • ʑΞΫςΟϒʹ։ൃத • ܧଓతͳ৽ػೳϦϦʔε • ແྉͰར༻Մೳ • ϑϧػೳʹ༗ྉϓϥϯͷܖ͕ඞཁ
None
Mackerel ͱܾࡁ
• ຖ݄ͷར༻࣮ʹԠͨ͡ैྔ՝ۚ • ར༻͍ͯ͠ΔϗετʢͳͲʣͷҠಈฏۉ • ελϯμʔυϗετ1/1݄͋ͨΓ1800ԁ • ܾࡁखஈ: جຊతʹΫϨδοτΧʔυ •
=> ΫϨδοτΧʔυܾࡁʹ Stripe
Stripe Mackerel Stripe.js v2 Mackerel JS Token Customer Token CardNumber,
etc Token
3/1 4/1 ݄͝ͱͷҠಈฏۉ
Stripe Payments Mackerel Charge.create( amount: 2*1800, customer: "XXX" ) ݄ॳόον
• ϘϦϡʔϜσΟεΧϯτͳͲಛผ݅͋Γ • ٻॻ͍͋Γ • ࠓΫϨδοτΧʔυͱผޱͰूܭ
Mackerel ͱܾࡁαʔϏε
• ݱࡏΫϨδοτΧʔυܾࡁ Stripe ܦ༝ • ࣮ Stripe ͕3ࣾ (2019/02~)
• αʔϏεϩʔϯν࣌ • ಛʹUSDܾࡁͰ Stripe બࢶʹ • JPYܾࡁͷΈͱͷஅ: WebPay Λબ
• (2014: Stripe ͷຊਐग़લ) 2014
• WebPay αʔϏεऴྃ • ಉ͡ࠒ Stripe ຊ্ • JCB ܾࡁ͕ඞཁ:
PayJp Λબ • 2018࣌Ͱ10%͕ JCB 2016~2017
• Stripe JCB ରԠʂʂʂʂʂ • ຬΛ࣋ͯ͠ Stripe Ҡߦ 2018~19
ܾࡁαʔϏεΛҠߦ͢Δ
• See Stripe docs ! • https://stripe.com/docs/ security/data-migrations
• ৽αʔϏεͰͷܾࡁϩδοΫ࣮ • ސ٬σʔλͷҠ • ܾࡁઌͷΓ͑ • ϨϙʔςΟϯάͷ࠶ߏங
• ࠔΔ͜ͱͦΜͳʹͳ͔ͬͨ • ϓϦϛςΟϒͳػೳͰ࣮ݱ͍ͯͨ͠ • ෳͷܾࡁαʔϏεΛಉ࣌ʹѻ͏͜ͱ͕ Մೳͳઃܭʹͳ͍ͬͯͨ ΤϯυϢʔβʔ͚ͷػೳҠߦ
• (چސ٬ id) => (৽ސ٬ id) ͷϚοϐϯά͕ඞཁ • αʔϏεؒͰσʔλҠߦ =>
ϚοϐϯάΛड͚औΔ • ࣄۀऀؒͷεέδϡʔϧௐ͕ඞཁɹ • ҠߦޙܾࡁͰ͖ͳ͘ͳͬͨͷ1%ఔ ސ٬σʔλͷσʔλҠߦ
৽نސ٬ 1BZ+Q طଘސ٬ 1BZ+Q ܾࡁ 1BZ+Q
৽نސ٬ 4USJQF طଘސ٬ 1BZ+Q ܾࡁ 4USJQF1BZ+Q
৽نސ٬ 4USJQF طଘސ٬ NJHSBUJPO ܾࡁ QFOEJOH
৽نސ٬ 4USJQF طଘސ٬ 4USJQF ܾࡁ 4USJQF
• ച্ɺೖۚͷαΠΫϧ͕มԽ͢Δ • ΧʔυϒϥϯυʹΑͬͯҟͳΔʂ • όοΫΦϑΟεͱௐɺ࣮ όοΫΦϑΟεͱͷ࿈ܞ
• Ҡߦཧͷػͱଊ͑Δ • Ϩϙʔτ༰ɾ࣌ظΛ࠶ઃܭ͢Δ
• ʮച্ΛకΊΔλΠϛϯάͰച্ͷ༁͕Γ͍ͨʂʯ • => Stripe ଆͷܾࡁҰཡ • ʮͦͷച্͕͍ͭೖۚ͞ΕΔ༧ఆͳͷ͔ʯΛؚΊΔ • ʮೖۚͷλΠϛϯάͰͦͷೖۚͷ༁͕Γ͍ͨʂʯ
• => Stripe ଆͷೖۚ༁ ʮ͍ͭɺͲͷࣈ͕ඞཁʁʯ
݄ച্"""ԁ ݄ೖۚ༧ఆQQQԁ ݄ೖۚ༧ఆRRRԁ ݄ച্###ԁ ݄ೖۚ༧ఆSSSԁ ݄ೖۚ༧ఆTTTԁ ݄ೖۚ:::ԁ ݄ച্RRRԁ ݄ച্SSSԁ ݄ೖۚ999ԁ
݄ച্PPPԁ ݄ച্QQQԁ
• Ϛελσʔλ Stripe ͷ API • ͳΜͰऔΕΔʂ • ඞཁͳՃใܾࡁ࣌ͰϝλσʔλʹؚΊΔ •
ʮϗετʯʮ৫໊ʯetc • API ܦ༝ͰϨϙʔτΛ࡞ • ޙॲཧΛՃ͔͑ͯΒόοΫΦϑΟεʹఏग़
Ҡߦ͠·ͨ͠
Stripe Mackerel Stripe.js v2 Mackerel JS CardNumber, etc Token Token
Token Customer ࠶ܝ
Stripe Payments Mackerel Customer.charge( amount: 2*1800, customer: "XXX" ) ݄ॳόον
࠶ܝ
• ࠓͷͱ͜ΖStripe ΛඇৗʹϓϦϛςΟϒʹ͍ͬͯΔ • Stripe ར༻ͱ͍͏ελʔτϥΠϯʹ • ͳΔͦ͘ͷ··Ҡߦ͢Δ͜ͱΛ༏ઌ • ΑΓϦονͳιϦϡʔγϣϯʹڵຯ͕͋Δʂʂ
• Elements / Billing • ࣮ࡍ Elements ͷҠߦΛ·͞ʹ࣮ࢪத
• ܧଓతʹαʔϏεશମΛվળ͍ͯ͘͠ • ܾࡁػೳ"Ҭ" ʹ͠ͳ͍ • ϢʔβʔɺϏδωεɺόοΫΦϑΟε SaaS ఏڙऀͱͯ͠
• ๛ͳػೳɾվળͷԸܙΛड͚͍ͯ͘ • ࠓޙͷ·͢·͢ͷύϫʔΞοϓʹظ • ࠷ۙٻॻʹ͍ͯ͠·͢ SaaS ར༻ऀͱͯ͠
͝ਗ਼ௌ͋Γ͕ͱ͏͍͟͝·ͨ͠