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
少し変わった論理削除
Search
Yusuke Yagyu
August 31, 2015
Technology
3
17k
少し変わった論理削除
論理削除 Casual Talks #1 (2015/08/31)
Yusuke Yagyu
August 31, 2015
Tweet
Share
More Decks by Yusuke Yagyu
See All by Yusuke Yagyu
ペパボのデザインシステムと、モバイル領域における取り組み
gyugyu
0
1.1k
Dart Sass であれを作った
gyugyu
0
76
Android CI: 2016 edition
gyugyu
3
2.3k
Other Decks in Technology
See All in Technology
Amazon CloudWatch Network Monitor のススメ
yuki_ink
1
200
VideoMamba: State Space Model for Efficient Video Understanding
chou500
0
190
DMARC 対応の話 - MIXI CTO オフィスアワー #04
bbqallstars
1
160
TanStack Routerに移行するのかい しないのかい、どっちなんだい! / Are you going to migrate to TanStack Router or not? Which one is it?
kaminashi
0
580
初心者向けAWS Securityの勉強会mini Security-JAWSを9ヶ月ぐらい実施してきての近況
cmusudakeisuke
0
120
TypeScriptの次なる大進化なるか!? 条件型を返り値とする関数の型推論
uhyo
2
1.6k
Lexical Analysis
shigashiyama
1
150
EventHub Startup CTO of the year 2024 ピッチ資料
eventhub
0
110
マルチプロダクトな開発組織で 「開発生産性」に向き合うために試みたこと / Improving Multi-Product Dev Productivity
sugamasao
1
300
【令和最新版】AWS Direct Connectと愉快なGWたちのおさらい
minorun365
PRO
5
750
Terraform未経験の御様に対してどの ように導⼊を進めていったか
tkikuchi
2
430
Terraform CI/CD パイプラインにおける AWS CodeCommit の代替手段
hiyanger
1
240
Featured
See All Featured
Intergalactic Javascript Robots from Outer Space
tanoku
269
27k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
29
2.3k
The Art of Programming - Codeland 2020
erikaheidi
52
13k
Building Flexible Design Systems
yeseniaperezcruz
327
38k
A Tale of Four Properties
chriscoyier
156
23k
Gamification - CAS2011
davidbonilla
80
5k
Java REST API Framework Comparison - PWX 2021
mraible
PRO
28
8.2k
Building Applications with DynamoDB
mza
90
6.1k
Happy Clients
brianwarren
98
6.7k
Adopting Sorbet at Scale
ufuk
73
9.1k
Art, The Web, and Tiny UX
lynnandtonic
297
20k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
6
410
Transcript
গ͠มΘͬͨཧআ ϗεςΟϯάαʔϏεʹ͓͚Δཧআͷྫ
var_dump($me); object(Engineer)#1 (3) { [“name”:private]=> string(12) “Yusuke Yagyu” [“nickname”:private]=> string(6)
“gyugyu” [“position”:private]=> string(35) “Senior engineer at GMO Pepabo, Inc.” [“leisure”:private]=> string(6) “Noder” }
Noder
None
None
None
None
ΑΖ͘͠ ͓ئ͍͠·͢
Sorry, I apologize for ͍ΘΏΔཧআΒ͍͠ཧআͷ͋·Γग़·ͤΜ ER ਤ SQL ग़͖ͯ·ͤΜ ͓͜ͱΘΓ
෮शɿཧআ ཧআͱ σʔλͷӬଓԽʹ͓͍ͯ ֘σʔλͷফڈͱผʹ σʔλ͕֎෦͔ΒࢀরෆೳͱͳΔঢ়ଶΛఆٛ͠ ͦͷঢ়ଶͱσʔλΛ্ॻ͖͢Δ͜ͱ Ͱ͋Δͱఆٛ͢Δɻ ཧআͱ
෮शɿཧআ del_flg ΧϥϜ༩ deleted_at ΧϥϜ༩ ঢ়ଶཧςʔϒϧ࡞ ཤྺςʔϒϧ࡞ ཧআɾ࣮
෮शɿཧআ ઃܭऀͷ RDBMS ʹର͢Δཧղෆ ઃܭऀͷσʔλϕʔειϑτΣΞʹର͢Δཧղෆ ઃܭऀͷυϝΠϯʹର͢Δཧղෆ Ϗδωεཁ݅ͱͯͦͦ͠ఆٛ͞Εͯ͠·͍ͬͯΔ ʢےͷѱ͍ʣཧআ͕࣮͞ΕΔഎܠ
Engineer in Wonderland
Engineer in Wonderland ཧআͱ σʔλͷӬଓԽʹ͓͍ͯ ֘σʔλͷফڈͱผʹ σʔλ͕֎෦͔ΒࢀরෆೳͱͳΔঢ়ଶΛఆٛ͠ ͦͷঢ়ଶͱσʔλΛ্ॻ͖͢Δ͜ͱ Ͱ͋Δͱఆٛ͢Δɻ ཧআͱ
Engineer in Wonderland ཧআͱ σʔλͷӬଓԽʹ͓͍ͯ ʢུʣ Ͱ͋Δͱఆٛ͢Δɻ ͨͩ͠ɺͦͷσʔλӬଓԽػߏ RDBMS ͱݶΒͳ͍ɻ
ཧআɾ࠶ఆٛ
Engineer in Wonderland ཧআͱ σʔλͷӬଓԽʹ͓͍ͯ ʢུʣ Ͱ͋Δͱఆٛ͢Δɻ ͨͩ͠ɺͦͷσʔλӬଓԽػߏ RDBMS ͱݶΒͳ͍ɻ
͞Βʹ୯ҰϨίʔυͷӬଓԽ͕ෳͷӬଓԽػߏʹ·͕ͨΔɻ ཧআɾ࠶ఆٛ
Hosting Service
Hosting Service Σϒαʔό ϝʔϧαʔό σʔλϕʔεαʔό DNS ֤छCMS ԿΛαʔϏε͢Δ͔
Hosting Service ྫͱͯ͠ΣϒαʔόͰ unix Ϣʔβ ϑΝΠϧγεςϜ ϑΝΠϧߦ RDBMS Ͳ͏ӬଓԽ͢Δ͔
Hosting Service usermod -L chmod 000 mv rmʢγϯϘϦοΫϦϯΫʣ ίϝϯτΞτ REVOKE
ඇ RDBMS ڥʹ͓͚Δཧআʢྫʣ
Hosting Service ϗεςΟϯάαʔϏεʹ͓͚Δཧআɺ RDBMS తཧআͱ࣮ͯ͠Ͱ͖ͳ͍ɻ ͳ͓͔ͭɺRDBMS Ͱͷཧআ͕ ඇ RDBMS ڥͰͷཧআͱͳΔύλʔϯ͕͋Δɻ
݁Ռɺཧআͷҙຯ͕ͿΕΔɻ
Hosting Service ϓϩμΫτΦʔφʔ ʮ͜ͷϢʔβɺআͰ͖ͳ͍͚ͲͳΜͰʁʯ ։ൃऀ ʮ͜ΕϢʔβͷཧআͳͷͰ͕͢ɺ ɹϑΝΠϧγεςϜ্ͷআͱ ɹϑΝΠϧͷίϝϯτΞτΛ࣮ࢪ͍ͯͯ͠ɺ ɹͦͷࡍʹఆ͞ΕΔߦ͕ͳ͔ͬͨͨΊɺ ɹϢʔβͷআϑϥά্͕͕͍ͬͯͳ͍ͷͰ͢ʯ
ྫʢ͋͘·Ͱ͜ΕྫͰ͢ʣ
Hosting Service ϓϩμΫτΦʔφʔ ʮϢʔβ͕আ͞ΕΔલʹ৽͘͠ঢ়ଶΛՃ͍ͨ͠Μ͚ͩͲʯ ։ൃऀ ʮ͜ͷػೳͱ͜ͷػೳΛཧআͯ͠ɺ ɹআϑϥάͱ͍ͯͬͯ͠ΔΧϥϜʹ৽͍͠ΛՃ͠·͠ΐ͏ʯ ྫʢ͋͘·Ͱ͜ΕྫͰ͢ʣ
!! Danger !!
ཧআͱఔΑ͍ڑײͰੜ͖Δ ։ൃऀԟʑʹͯ͠෦࣮ΛޠΓ͗͢Δ ඇ։ൃऀআ͕ཧ͔ཧ͔͠ͳ͍ ʮཧআʯͱ͍͏ݴ༿͕ຊʹత֬ͳදݱ͔ʁ ྫɿୀձϢʔβʁɹແޮϢʔβʁɹআͪϢʔβʁ ຊʹඞཁͳ࣌Ҏ֎ʮཧআʯͱ͍͏୯ޠΛආ͚Δ ྫɿ։ൃऀͱ͍ͯͯ֓͠೦Λཧআͱ͔͠දݱͰ͖ͳ͍߹ ཧআͱݴΘͳ͍
ཧআͱఔΑ͍ڑײͰੜ͖Δ ཧআʴϩΪϯάʹͰ͖ͳ͍͔ ཧআͰͳ͘ঢ়ଶཧͰͳ͍͔ ػೳՃɺཁ݅ͷมߋʹରͯ͠։͔Ε͍ͯΔ͔ Ϗδωεཁ݅ͱͯ͠ඞਢͷ࣌ؤுΔ ཧআΛආ͚Δ
ཧআͱఔΑ͍ڑײͰੜ͖Δ ཧআͱݴ͍ग़͢ͷσʔλͷ࣋ͪํʹनΘΕ͗͢Ͱʁ ຊདྷྗ͖͢υϝΠϯʹྗͰ͖͍ͯͳ͍ͷͰʁ ͦͦ
DDD ʰυϝΠϯۦಈઃܭʱEric Evans ʰ࣮ફυϝΠϯۦಈઃܭʱVaughn Vernon
·ͱΊ ཧআ RDBMS ʹݶΒͣɺ༷ʑͳܗͷཧআ͕ଘࡏ͠͏Δ ӬଓԽػߏ͕ෳଘࡏ͢Δͱɺཧআෳࡶ͞ͷݪҼʹͳΔ ෳࡶͳཧআΛੜͰѻ͏ΑΓɺత֬ͳঢ়ଶදݱΛఆٛ͢Δ ӬଓԽػߏ͕ෳଘࡏ͢Δ͜ͱͰɺ݁ՌతʹυϝΠϯͷ·ͳ͟͠ ͕ᔻཆ͞ΕΔ ཧআͱ͍͏୯ޠ RDBMS
͚ͩͷͷͰͳ͍