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
運用中の Rails アプリをマルチテナント対応して新規サービスをリリースするまでの道のり
Search
Yuta Takahashi
August 25, 2022
Programming
1
2.9k
運用中の Rails アプリをマルチテナント対応して新規サービスをリリースするまでの道のり
2022/08/25 開催
【Railsエンジニア集合!】身近だけど知らないtoBサービスの裏側をのぞく
https://estie.connpass.com/event/255928/
Yuta Takahashi
August 25, 2022
Tweet
Share
More Decks by Yuta Takahashi
See All by Yuta Takahashi
開発チームの生産性向上に取り組む
ytakahashi
1
650
詳解 WindowInsets
ytakahashi
4
3k
Navigation Architecture Component によるアプリ内遷移の管理
ytakahashi
14
7k
MotionLayout Basics
ytakahashi
3
900
Other Decks in Programming
See All in Programming
Go コードベースの構成と AI コンテキスト定義
andpad
0
150
【卒業研究】会話ログ分析によるユーザーごとの関心に応じた話題提案手法
momok47
0
140
tparseでgo testの出力を見やすくする
utgwkk
2
310
Jetpack XR SDKから紐解くAndroid XR開発と技術選定のヒント / about-androidxr-and-jetpack-xr-sdk
drumath2237
1
200
Developing static sites with Ruby
okuramasafumi
0
330
AIエンジニアリングのご紹介 / Introduction to AI Engineering
rkaga
8
3.4k
PC-6001でPSG曲を鳴らすまでを全部NetBSD上の Makefile に押し込んでみた / osc2025hiroshima
tsutsui
0
200
Navigating Dependency Injection with Metro
l2hyunwoo
1
200
令和最新版Android Studioで化石デバイス向けアプリを作る
arkw
0
460
AI Agent Tool のためのバックエンドアーキテクチャを考える #encraft
izumin5210
5
1.4k
TerraformとStrands AgentsでAmazon Bedrock AgentCoreのSSO認証付きエージェントを量産しよう!
neruneruo
4
2.1k
マスタデータ問題、マイクロサービスでどう解くか
kts
0
150
Featured
See All Featured
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
280
Building a Modern Day E-commerce SEO Strategy
aleyda
45
8.4k
The Limits of Empathy - UXLibs8
cassininazir
1
200
The Curious Case for Waylosing
cassininazir
0
200
How People are Using Generative and Agentic AI to Supercharge Their Products, Projects, Services and Value Streams Today
helenjbeal
1
84
The SEO identity crisis: Don't let AI make you average
varn
0
39
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
Applied NLP in the Age of Generative AI
inesmontani
PRO
3
2k
Tell your own story through comics
letsgokoyo
0
770
Effective software design: The role of men in debugging patriarchy in IT @ Voxxed Days AMS
baasie
0
180
A Soul's Torment
seathinner
1
2k
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
0
1k
Transcript
Rails 2 022 . 8 . 2 5 Thu
toB
yt-tkhs yt_hizi Android 2021 7 Flutter / Rails
: atohama SaaS
UUUO atohama 1 Rails ߪೖऀ༻ΞϓϦ ग़༻ΞϓϦ ߪೖऀ༻ΞϓϦ αʔόʔ
( )
: https://d 1 .awsstatic.com/whitepapers/ja_JP/saas-tenant-isolation-strategies.pdf
: https://d 1 .awsstatic.com/whitepapers/ja_JP/saas-tenant-isolation-strategies.pdf
citusdata/activerecord-multi-tenant gem User.all SELECT * FROM users; SELECT * FROM
users WHERE tenant_id = 1;
⾒ ID (Push )
ID (Push )
ID class Organization UUUO_ID = 1.freeze def uuuo? id ==
UUUO_ID end end
ID :
( ) ( ) ( )
None
( )
Before 1 . 2 . 1 . 2 . 3
. After
Before 1 . 2 . 1 . 2 . 3
. After
class Organization def tenant_owner? id == tenant.owner_organization_id end def tenant_admin?
is_admin end end
class Organization def tenant_owner? id == tenant.owner_organization_id end def tenant_admin?
is_admin end end ID
class Organization def tenant_owner? id == tenant.owner_organization_id end def tenant_admin?
is_admin end end
: ID
ID ID UUUO atohama ߪೖऀ༻ΞϓϦ ग़༻ΞϓϦ ߪೖऀ༻ΞϓϦ αʔόʔ
ID Push ID Push UUUO jp.uuuo.maehama jp.uuuo.atohama A jp.uuuo.atohama.xxx
ID ID ( DB ) ID
ID : ID ⾒
⾒ ID (Push )
None
citusdata/activerecord-multi-tenant
Thank you! microsoft/fluentui-emoji: https://github.com/microsoft/fluentui-emoji/blob/main/LICENSE