From 994186f2672547761392c71ed15ded2a83e8c20d Mon Sep 17 00:00:00 2001 From: Machiavelli Date: Sat, 21 Aug 2010 03:19:25 +0200 Subject: DB Layer: - Make SQL Transactions actual objects used in code. (Thanks to Derex for the idea) * Uncommitted transactions will be automatically rolled back and cleaned up using ACE_Refcounted_Auto_Ptr, so no need to call Rollback() in the code. * Prevents recursive transactions and makes developers aware of transactions going on. * Gets rid of unneccesary overhead iterating over a concurrent map. - Some cleanups in affected code, including better usage of transaction control in AH / mail related code to prevent data loss. *** Experimental, use at own risk, recommended to backup your DBs. *** --HG-- branch : trunk --- src/server/shared/Database/SQLOperation.h | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'src/server/shared/Database/SQLOperation.h') diff --git a/src/server/shared/Database/SQLOperation.h b/src/server/shared/Database/SQLOperation.h index a8238802e31..0c5fe08d94e 100644 --- a/src/server/shared/Database/SQLOperation.h +++ b/src/server/shared/Database/SQLOperation.h @@ -59,19 +59,7 @@ class BasicStatementTask : public SQLOperation QueryResultFuture m_result; }; -/*! Transactions */ -class TransactionTask : public SQLOperation -{ - public: - TransactionTask(); - ~TransactionTask(); - void ForcefulDelete(); - - bool Execute(); - private: - std::queue m_queries; -}; class SQLQueryHolder { -- cgit v1.2.3