From 31fb448cfc9c43532c38a58fff75fb6c0e67d632 Mon Sep 17 00:00:00 2001 From: Tom Date: Wed, 26 Jan 2011 17:06:17 -0800 Subject: Mostly revert the last commit with the aim of searching for a better solution --- .../UserAccounts/LocalUserAccountServiceConnector.cs | 17 ++++------------- OpenSim/Region/Framework/Scenes/Scene.cs | 2 +- .../SimianGrid/SimianUserAccountServiceConnector.cs | 5 ----- .../UserAccounts/UserAccountServiceConnector.cs | 5 ----- OpenSim/Services/HypergridService/UserAccountCache.cs | 5 ----- OpenSim/Services/Interfaces/IUserAccountService.cs | 1 - .../Services/UserAccountService/UserAccountService.cs | 5 ----- 7 files changed, 5 insertions(+), 35 deletions(-) (limited to 'OpenSim') diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/UserAccounts/LocalUserAccountServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/UserAccounts/LocalUserAccountServiceConnector.cs index 54340e6..9ecbcc6 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/UserAccounts/LocalUserAccountServiceConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/UserAccounts/LocalUserAccountServiceConnector.cs @@ -142,19 +142,10 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.UserAccounts public UserAccount GetUserAccount(UUID scopeID, UUID userID) { - return GetUserAccount(scopeID, userID, true); - } - - public UserAccount GetUserAccount(UUID scopeID, UUID userID, bool useCache) - { - UserAccount account; - if (useCache) - { - bool inCache = false; - account = m_Cache.Get(userID, out inCache); - if (inCache) - return account; - } + bool inCache = false; + UserAccount account = m_Cache.Get(userID, out inCache); + if (inCache) + return account; account = m_UserService.GetUserAccount(scopeID, userID); m_Cache.Cache(userID, account); diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index 99248c1..236e9c1 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs @@ -2559,7 +2559,7 @@ namespace OpenSim.Region.Framework.Scenes else { */ - UserAccount uac = UserAccountService.GetUserAccount(RegionInfo.ScopeID, user, false); + UserAccount uac = UserAccountService.GetUserAccount(RegionInfo.ScopeID, user); return uac.UserFlags; //} } diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianUserAccountServiceConnector.cs b/OpenSim/Services/Connectors/SimianGrid/SimianUserAccountServiceConnector.cs index fe4e2bf..801b424 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianUserAccountServiceConnector.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianUserAccountServiceConnector.cs @@ -131,11 +131,6 @@ namespace OpenSim.Services.Connectors.SimianGrid public UserAccount GetUserAccount(UUID scopeID, UUID userID) { - return GetUserAccount(scopeID, userID, true); - } - - public UserAccount GetUserAccount(UUID scopeID, UUID userID, bool useCache) - { // Cache check UserAccount account; if (m_accountCache.TryGetValue(userID, out account)) diff --git a/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs b/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs index c21b250..205a4aa 100644 --- a/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs +++ b/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs @@ -113,11 +113,6 @@ namespace OpenSim.Services.Connectors public virtual UserAccount GetUserAccount(UUID scopeID, UUID userID) { - return GetUserAccount(scopeID, userID, true); - } - - public virtual UserAccount GetUserAccount(UUID scopeID, UUID userID, bool useCache) - { //m_log.DebugFormat("[ACCOUNTS CONNECTOR]: GetUserAccount {0}", userID); Dictionary sendData = new Dictionary(); //sendData["SCOPEID"] = scopeID.ToString(); diff --git a/OpenSim/Services/HypergridService/UserAccountCache.cs b/OpenSim/Services/HypergridService/UserAccountCache.cs index bbc531e..e0a3e61 100644 --- a/OpenSim/Services/HypergridService/UserAccountCache.cs +++ b/OpenSim/Services/HypergridService/UserAccountCache.cs @@ -80,11 +80,6 @@ namespace OpenSim.Services.HypergridService return GetUser(userID.ToString()); } - public UserAccount GetUserAccount(UUID scopeID, UUID userID, bool useCache) - { - return GetUser(userID.ToString()); - } - public UserAccount GetUserAccount(UUID scopeID, string FirstName, string LastName) { return null; diff --git a/OpenSim/Services/Interfaces/IUserAccountService.cs b/OpenSim/Services/Interfaces/IUserAccountService.cs index 21be98c..a91aa0f 100644 --- a/OpenSim/Services/Interfaces/IUserAccountService.cs +++ b/OpenSim/Services/Interfaces/IUserAccountService.cs @@ -143,7 +143,6 @@ namespace OpenSim.Services.Interfaces public interface IUserAccountService { - UserAccount GetUserAccount(UUID scopeID, UUID userID, bool useCache); UserAccount GetUserAccount(UUID scopeID, UUID userID); UserAccount GetUserAccount(UUID scopeID, string FirstName, string LastName); UserAccount GetUserAccount(UUID scopeID, string Email); diff --git a/OpenSim/Services/UserAccountService/UserAccountService.cs b/OpenSim/Services/UserAccountService/UserAccountService.cs index b914668..cbd6f35 100644 --- a/OpenSim/Services/UserAccountService/UserAccountService.cs +++ b/OpenSim/Services/UserAccountService/UserAccountService.cs @@ -208,11 +208,6 @@ namespace OpenSim.Services.UserAccountService public UserAccount GetUserAccount(UUID scopeID, UUID principalID) { - return GetUserAccount(scopeID, principalID, true); - } - - public UserAccount GetUserAccount(UUID scopeID, UUID principalID, bool useCache) - { UserAccountData[] d; if (scopeID != UUID.Zero) -- cgit v1.1