logo
首页技术栈工具库讨论
consistency_fail

consistency_fail

With more than one application server, validates_uniqueness_of becomes a lie. Two app servers -> two requests -> two near-simultaneous uniqueness checks -> two processes that commit to the database independently, violating this faux constraint. You'll need a database-level constraint for cases like these. consistency_fail will find your missing unique indexes, so you can add them and stop ignoring the C in ACID.
由 
bruceshi2021-01-13 收录
--
推荐
不推荐
更多信息
RUBYGEMS
gem install consistency_fail
查看
标签
根据用户添加的标签生成
暂无标签