加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

c# – TransactionScope和“持久资源”

发布时间:2020-12-15 08:12:58 所属栏目:百科 来源:网络整理
导读:有关TransactionScope对象的快速问题.在互联网上找到这个: When you access your first durable resource manager,a lightweight committable transaction is created to support the single transaction. When you access a second durable resource manag
有关TransactionScope对象的快速问题.在互联网上找到这个:

When you access your first durable resource manager,a lightweight
committable transaction is created to support the single transaction.
When you access a second durable resource manager,the transaction is
promoted to a distributed transaction.

这似乎很好,但我不明白究竟什么是“持久资源”.我知道TransactionScope只适用于SQL Server 2005及更高版本,所以如果我需要访问SQL Server 200,那么它不可能吗?磁盘上的文本文件怎么样?我一直听说你在涉及磁盘访问时无法进行事务控制.也许这个对象有所不同吗?

谢谢!

解决方法

This link讨论了持久性和易变性资源管理器之间的差异.

只是为了澄清 – TransactionScopes将与earlier versions of SQL一起使用,但轻量级事务管理器仅适用于2005.对于SQL 2000的事务,将需要DTC.

还支持事务性文件系统(Vista及更高版本) – 看看here.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读