From 4a58e53acdd89031eeeca03642223553de90090a Mon Sep 17 00:00:00 2001 From: inga-lovinde <52715130+inga-lovinde@users.noreply.github.com> Date: Tue, 6 Jul 2010 06:19:14 +0000 Subject: [PATCH] Default transaction isolation level changed to 'ReadCommited' --- Core/DB/IDBConnection.cs | 2 +- IISMainHandler/handlers/DebugHandler.cs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Core/DB/IDBConnection.cs b/Core/DB/IDBConnection.cs index 58c270c..49c3ed7 100644 --- a/Core/DB/IDBConnection.cs +++ b/Core/DB/IDBConnection.cs @@ -41,7 +41,7 @@ namespace FLocal.Core.DB { } public static Transaction beginTransaction(this IDBConnection connection) { - return connection.beginTransaction(System.Data.IsolationLevel.Snapshot); + return connection.beginTransaction(System.Data.IsolationLevel.ReadCommitted); } public static Dictionary LoadById(this IDBConnection connection, ITableSpec table, string id) { diff --git a/IISMainHandler/handlers/DebugHandler.cs b/IISMainHandler/handlers/DebugHandler.cs index 39e95b8..def7d3f 100644 --- a/IISMainHandler/handlers/DebugHandler.cs +++ b/IISMainHandler/handlers/DebugHandler.cs @@ -3,6 +3,7 @@ using System.Collections.Generic; using System.Linq; using System.Text; using System.Web; +using FLocal.Core.DB; using FLocal.Common.dataobjects; namespace FLocal.IISHandler.handlers { @@ -22,7 +23,7 @@ namespace FLocal.IISHandler.handlers { context.httpresponse.WriteLine("AppInfo: " + context.config.AppInfo); context.httpresponse.WriteLine("InitTime: " + context.config.InitTime); if(context.httprequest.Path == "/test/") { - using(Core.DB.Transaction transaction = context.config.mainConnection.beginTransaction(System.Data.IsolationLevel.Snapshot)) { + using(Transaction transaction = context.config.mainConnection.beginTransaction()) { context.httpresponse.WriteLine(transaction.GetHashCode().ToString()); } }