Get PGSQL UserProfilesData to log the exception trace for debugging rather than just the exception message.
parent
dbd500db42
commit
38590a4fad
|
@ -119,9 +119,9 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: UserAccount exception ", e);
|
||||||
": UserAccount exception {0}", e.Message);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
n.Add("classifieduuid", OSD.FromUUID(Id));
|
n.Add("classifieduuid", OSD.FromUUID(Id));
|
||||||
n.Add("name", OSD.FromString(Name));
|
n.Add("name", OSD.FromString(Name));
|
||||||
data.Add(n);
|
data.Add(n);
|
||||||
|
@ -212,15 +212,14 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: ClassifiedsUpdate exception ", e);
|
||||||
": ClassifiedesUpdate exception {0}", e.Message);
|
|
||||||
result = e.Message;
|
result = e.Message;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public bool DeleteClassifiedRecord(UUID recordId)
|
public bool DeleteClassifiedRecord(UUID recordId)
|
||||||
{
|
{
|
||||||
string query = string.Empty;
|
string query = string.Empty;
|
||||||
|
@ -246,10 +245,10 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: DeleteClassifiedRecord exception ", e);
|
||||||
": DeleteClassifiedRecord exception {0}", e.Message);
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -295,13 +294,14 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: GetClassifiedInfo exception ", e);
|
||||||
": GetClassifiedInfo exception {0}", e.Message);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static UUID GetUUID( object uuidValue ) {
|
public static UUID GetUUID(object uuidValue)
|
||||||
|
{
|
||||||
|
|
||||||
UUID ret = UUID.Zero;
|
UUID ret = UUID.Zero;
|
||||||
|
|
||||||
|
@ -310,7 +310,6 @@ namespace OpenSim.Data.PGSQL
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#endregion Classifieds Queries
|
#endregion Classifieds Queries
|
||||||
|
|
||||||
#region Picks Queries
|
#region Picks Queries
|
||||||
|
@ -350,9 +349,9 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: GetAvatarPicks exception ", e);
|
||||||
": GetAvatarPicks exception {0}", e.Message);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return data;
|
return data;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -407,9 +406,9 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: GetPickInfo exception ", e);
|
||||||
": GetPickInfo exception {0}", e.Message);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return pick;
|
return pick;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -460,10 +459,10 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: UpdateAvatarNotes exception ", e);
|
||||||
": UpdateAvatarNotes exception {0}", e.Message);
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -490,15 +489,17 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: DeleteUserPickRecord exception ", e);
|
||||||
": DeleteUserPickRecord exception {0}", e.Message);
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion Picks Queries
|
#endregion Picks Queries
|
||||||
|
|
||||||
#region Avatar Notes Queries
|
#region Avatar Notes Queries
|
||||||
|
|
||||||
public bool GetAvatarNotes(ref UserProfileNotes notes)
|
public bool GetAvatarNotes(ref UserProfileNotes notes)
|
||||||
{ // WIP
|
{ // WIP
|
||||||
string query = string.Empty;
|
string query = string.Empty;
|
||||||
|
@ -531,9 +532,9 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: GetAvatarNotes exception ", e);
|
||||||
": GetAvatarNotes exception {0}", e.Message);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -542,7 +543,7 @@ namespace OpenSim.Data.PGSQL
|
||||||
string query = string.Empty;
|
string query = string.Empty;
|
||||||
bool remove;
|
bool remove;
|
||||||
|
|
||||||
if(string.IsNullOrEmpty(note.Notes))
|
if (string.IsNullOrEmpty(note.Notes))
|
||||||
{
|
{
|
||||||
remove = true;
|
remove = true;
|
||||||
query += "DELETE FROM usernotes WHERE ";
|
query += "DELETE FROM usernotes WHERE ";
|
||||||
|
@ -571,6 +572,7 @@ namespace OpenSim.Data.PGSQL
|
||||||
{
|
{
|
||||||
if(!remove)
|
if(!remove)
|
||||||
cmd.Parameters.Add(m_database.CreateParameter("Notes", note.Notes));
|
cmd.Parameters.Add(m_database.CreateParameter("Notes", note.Notes));
|
||||||
|
|
||||||
cmd.Parameters.Add(m_database.CreateParameter("TargetId", note.TargetId));
|
cmd.Parameters.Add(m_database.CreateParameter("TargetId", note.TargetId));
|
||||||
cmd.Parameters.Add(m_database.CreateParameter("UserId", note.UserId));
|
cmd.Parameters.Add(m_database.CreateParameter("UserId", note.UserId));
|
||||||
|
|
||||||
|
@ -580,16 +582,17 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: UpdateAvatarNotes exception ", e);
|
||||||
": UpdateAvatarNotes exception {0}", e.Message);
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion Avatar Notes Queries
|
#endregion Avatar Notes Queries
|
||||||
|
|
||||||
#region Avatar Properties
|
#region Avatar Properties
|
||||||
|
|
||||||
public bool GetAvatarProperties(ref UserProfileProperties props, ref string result)
|
public bool GetAvatarProperties(ref UserProfileProperties props, ref string result)
|
||||||
{
|
{
|
||||||
string query = string.Empty;
|
string query = string.Empty;
|
||||||
|
@ -706,11 +709,11 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: GetAvatarProperties exception ", e);
|
||||||
": Requst properties exception {0}", e.Message);
|
|
||||||
result = e.Message;
|
result = e.Message;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -746,16 +749,17 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: AgentPropertiesUpdate exception ", e);
|
||||||
": AgentPropertiesUpdate exception {0}", e.Message);
|
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion Avatar Properties
|
#endregion Avatar Properties
|
||||||
|
|
||||||
#region Avatar Interests
|
#region Avatar Interests
|
||||||
|
|
||||||
public bool UpdateAvatarInterests(UserProfileProperties up, ref string result)
|
public bool UpdateAvatarInterests(UserProfileProperties up, ref string result)
|
||||||
{
|
{
|
||||||
string query = string.Empty;
|
string query = string.Empty;
|
||||||
|
@ -788,13 +792,14 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: AgentInterestsUpdate exception ", e);
|
||||||
": AgentInterestsUpdate exception {0}", e.Message);
|
|
||||||
result = e.Message;
|
result = e.Message;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion Avatar Interests
|
#endregion Avatar Interests
|
||||||
|
|
||||||
public OSDArray GetUserImageAssets(UUID avatarId)
|
public OSDArray GetUserImageAssets(UUID avatarId)
|
||||||
|
@ -868,13 +873,14 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: GetAvatarNotes exception ", e);
|
||||||
": GetAvatarNotes exception {0}", e.Message);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return data;
|
return data;
|
||||||
}
|
}
|
||||||
|
|
||||||
#region User Preferences
|
#region User Preferences
|
||||||
|
|
||||||
public bool GetUserPreferences(ref UserPreferences pref, ref string result)
|
public bool GetUserPreferences(ref UserPreferences pref, ref string result)
|
||||||
{
|
{
|
||||||
string query = string.Empty;
|
string query = string.Empty;
|
||||||
|
@ -922,10 +928,10 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: GetUserPreferences exception ", e);
|
||||||
": Get preferences exception {0}", e.Message);
|
|
||||||
result = e.Message;
|
result = e.Message;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -960,16 +966,18 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: AgentInterestsUpdate exception ", e);
|
||||||
": AgentInterestsUpdate exception {0}", e.Message);
|
|
||||||
result = e.Message;
|
result = e.Message;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion User Preferences
|
#endregion User Preferences
|
||||||
|
|
||||||
#region Integration
|
#region Integration
|
||||||
|
|
||||||
public bool GetUserAppData(ref UserAppData props, ref string result)
|
public bool GetUserAppData(ref UserAppData props, ref string result)
|
||||||
{
|
{
|
||||||
string query = string.Empty;
|
string query = string.Empty;
|
||||||
|
@ -1023,11 +1031,11 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: GetUserAppData exception ", e);
|
||||||
": Requst application data exception {0}", e.Message);
|
|
||||||
result = e.Message;
|
result = e.Message;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1063,13 +1071,13 @@ namespace OpenSim.Data.PGSQL
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[PROFILES_DATA]" +
|
m_log.Error("[PROFILES_DATA]: SetUserData exception ", e);
|
||||||
": SetUserData exception {0}", e.Message);
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion Integration
|
#endregion Integration
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue