关于业务逻辑层(bll)的事务(transactions)

http://forums.asp.net/t/1183564.aspx

在这里提出了一个我也想问的问题

问题描述:

bll 4个类 blla bllb bllc blld

blld.f()

{

blla.f();

bllb.f();

bllc.f();

}

这里 bllc.f();发生异常要撤销bllb.f();blla.f();

解决

1:

http://forums.asp.net/t/1183564.aspx这里的回复里提出用

System.Transactions
详见 http://www.cnblogs.com/ltp/archive/2009/06/17/1505319.html
2:
blld.f() 用独立的代码实现

blla.f();

bllb.f();

bllc.f();

以上功能用同一个数据库连接 然后用数据库的事务

希望有相关经验的高手进来指点指点

问题已经发布在

http://space.cnblogs.com/q/20319/

posted @ 2010-11-25 11:50  liuwei0514  Views(449)  Comments(0Edit  收藏  举报