只是一個關於在ActiveRecord中使用TransactionScope的快速問題。這是使用和運作的東西,還是人們使用其他一些處理交易的方法。我不太熟悉,而且我沒有使用AC,但我正在考慮爲我的項目採用SessionScope和TransactionScope,並且只是在想知道人們對它的看法。Castle ActiveRecord:TransactionScope
0
A
回答
1
如果你可以使用溫莎,我建議使用ActiveRecordIntegration facility結合使用Castle.Services.Transaction的Automatic Transaction Management Facility它允許你聲明應用事務,例如:
;
[Transactional]
public class BusinessClass
{
public void Load(int id)
{
...
}
// note the "virtual"
[Transaction(TransactionMode.Requires)]
public virtual void Save(Data data)
{
...
}
}
+0
不,我沒有使用Windsor,但對他們的TransactionScope實現感興趣。我實際上能夠把它翻出來並在我的項目中使用它。 – epitka 2010-01-06 21:15:42
相關問題
- 1. Wcf Castle Windsor
- 2. Castle Windsor問題
- 3. Castle Windsor Build Error
- 4. Castle ActiveRecord加入
- 5. Castle Windsor WCFFacility compression
- 6. SecurityException和Bouncy Castle
- 7. Castle Windsor的DictionaryAdapter
- 8. Castle MonoRail&ELMAH
- 9. SubSonic與Castle ActiveRecord
- 10. bouncy castle DefaultSignatureAlgorithmIdentifierFinder NoSuchFieldError:gostR3410_94
- 11. Castle Windsor Transient Disposables
- 12. Castle windsor註冊
- 13. Castle Windsor BuildUp
- 14. Castle Windsor&Command Pattern
- 15. Castle Windsor InternalsVisibleTo Silverlight
- 16. castle activerecord rewrite sql
- 17. WCF Castle Windsor和WAS
- 18. Cast Castle IControllerProxy到ControllerBase
- 19. Castle Logging Facility和log4net.Config.XmlConfigurator
- 20. Castle WcfFacility Publishing MEX Endpoints
- 21. Castle ActiveRecord中的TryFindByPrimaryKey
- 22. MVC與Castle Windsor RegisterForDispose
- 23. Castle Windsor Generic Typed Factory
- 24. Castle Windsor ILazyComponentLoader遞歸
- 25. Castle ILazyComponentLoader not攔截
- 26. Java Bouncy Castle OCSP Url
- 27. Castle Project ActiveRecord與XML
- 28. Castle Windsor Log4Net問題
- 29. Castle Windsor Weak Typed Factory
- 30. Castle ActiveRecordMediator Key not found
請告訴我們您的具體問題。你有沒有看到任何錯誤?意外的行爲? – 2009-12-26 23:12:21