持久性不是数据库的属性而不是事务的属性吗?
当人们谈论事务的属性时,人们总是说事务有四个属性,ACID。对于耐久性,通常的解释是
持久性意味着,一旦提交事务,它将保留在系统中 - 即使事务后立即发生系统崩溃。
我对此有点困惑。持久性不是数据库的一个属性吗?我们使用数据库来保证数据的持久性。即使我不使用事务,例如直接使用简单的 UPDATE,我的更改仍将保留在数据库中。
那么为什么人们强调持久性作为交易的属性呢?
When people talk about properties of the transaction, people always say the trasaction has four properties, ACID. For durability, a usual explanation is
Durability means that, once a transaction is committed, it will remain in the system – even if there’s a system crash immediately following the transaction.
I'm a bit confused about this. Isn't durability a property of a database? We use database for data durability. Even if I don't use a transaction, such as using a simple UPDATE
directly, my change will still be preserved in the DB.
So why do people emphasize the durability
as a property of a transaction?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论