Loading django/db/backends/__init__.py +0 −2 Original line number Diff line number Diff line Loading @@ -181,8 +181,6 @@ class BaseDatabaseWrapper(object): """ if self.transaction_state: return self.transaction_state[-1] # Note that this setting isn't documented, and is only used here, and # in enter_transaction_management() return settings.TRANSACTIONS_MANAGED def managed(self, flag=True): Loading docs/ref/settings.txt +10 −0 Original line number Diff line number Diff line Loading @@ -2069,6 +2069,16 @@ to ensure your processes are running in the correct environment. .. _pytz: http://pytz.sourceforge.net/ .. setting:: TRANSACTIONS_MANAGED TRANSACTIONS_MANAGED -------------------- Default: ``False`` Set this to ``True`` if you want to :ref:`disable Django's transaction management <deactivate-transaction-management>` and implement your own. .. setting:: USE_ETAGS USE_ETAGS Loading docs/topics/db/transactions.txt +3 −1 Original line number Diff line number Diff line Loading @@ -208,11 +208,13 @@ This applies to all database operations, not just write operations. Even if your transaction only reads from the database, the transaction must be committed or rolled back before you complete a request. .. _deactivate-transaction-management: How to globally deactivate transaction management ================================================= Control freaks can totally disable all transaction management by setting ``DISABLE_TRANSACTION_MANAGEMENT`` to ``True`` in the Django settings file. :setting:`TRANSACTIONS_MANAGED` to ``True`` in the Django settings file. If you do this, Django won't provide any automatic transaction management whatsoever. Middleware will no longer implicitly commit transactions, and Loading Loading
django/db/backends/__init__.py +0 −2 Original line number Diff line number Diff line Loading @@ -181,8 +181,6 @@ class BaseDatabaseWrapper(object): """ if self.transaction_state: return self.transaction_state[-1] # Note that this setting isn't documented, and is only used here, and # in enter_transaction_management() return settings.TRANSACTIONS_MANAGED def managed(self, flag=True): Loading
docs/ref/settings.txt +10 −0 Original line number Diff line number Diff line Loading @@ -2069,6 +2069,16 @@ to ensure your processes are running in the correct environment. .. _pytz: http://pytz.sourceforge.net/ .. setting:: TRANSACTIONS_MANAGED TRANSACTIONS_MANAGED -------------------- Default: ``False`` Set this to ``True`` if you want to :ref:`disable Django's transaction management <deactivate-transaction-management>` and implement your own. .. setting:: USE_ETAGS USE_ETAGS Loading
docs/topics/db/transactions.txt +3 −1 Original line number Diff line number Diff line Loading @@ -208,11 +208,13 @@ This applies to all database operations, not just write operations. Even if your transaction only reads from the database, the transaction must be committed or rolled back before you complete a request. .. _deactivate-transaction-management: How to globally deactivate transaction management ================================================= Control freaks can totally disable all transaction management by setting ``DISABLE_TRANSACTION_MANAGEMENT`` to ``True`` in the Django settings file. :setting:`TRANSACTIONS_MANAGED` to ``True`` in the Django settings file. If you do this, Django won't provide any automatic transaction management whatsoever. Middleware will no longer implicitly commit transactions, and Loading