From 1f402fdf5e8ef53a07f98c4447946805791d26bc Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Tue, 7 Feb 2012 21:40:28 +0000 Subject: Add url to logging if SynchronousRestFormsRequester.MakRequest() throws an exception in service connectors --- .../UserAccounts/UserAccountServiceConnector.cs | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs') diff --git a/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs b/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs index f6835b9..609dafe 100644 --- a/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs +++ b/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs @@ -138,11 +138,12 @@ namespace OpenSim.Services.Connectors string reply = string.Empty; string reqString = ServerUtils.BuildQueryString(sendData); + string uri = m_ServerURI + "/accounts"; // m_log.DebugFormat("[ACCOUNTS CONNECTOR]: queryString = {0}", reqString); try { reply = SynchronousRestFormsRequester.MakeRequest("POST", - m_ServerURI + "/accounts", + uri, reqString); if (reply == null || (reply != null && reply == string.Empty)) { @@ -152,7 +153,7 @@ namespace OpenSim.Services.Connectors } catch (Exception e) { - m_log.DebugFormat("[ACCOUNT CONNECTOR]: Exception when contacting accounts server: {0}", e.Message); + m_log.DebugFormat("[ACCOUNT CONNECTOR]: Exception when contacting user accounts server at {0}: {1}", uri, e.Message); } List accounts = new List(); @@ -206,11 +207,12 @@ namespace OpenSim.Services.Connectors { string reply = string.Empty; string reqString = ServerUtils.BuildQueryString(sendData); + string uri = m_ServerURI + "/accounts"; // m_log.DebugFormat("[ACCOUNTS CONNECTOR]: queryString = {0}", reqString); try { reply = SynchronousRestFormsRequester.MakeRequest("POST", - m_ServerURI + "/accounts", + uri, reqString); if (reply == null || (reply != null && reply == string.Empty)) { @@ -220,7 +222,7 @@ namespace OpenSim.Services.Connectors } catch (Exception e) { - m_log.DebugFormat("[ACCOUNT CONNECTOR]: Exception when contacting user account server: {0}", e.Message); + m_log.DebugFormat("[ACCOUNT CONNECTOR]: Exception when contacting user accounts server at {0}: {1}", uri, e.Message); } Dictionary replyData = ServerUtils.ParseXmlResponse(reply); @@ -241,11 +243,12 @@ namespace OpenSim.Services.Connectors private bool SendAndGetBoolReply(Dictionary sendData) { string reqString = ServerUtils.BuildQueryString(sendData); + string uri = m_ServerURI + "/accounts"; // m_log.DebugFormat("[ACCOUNTS CONNECTOR]: queryString = {0}", reqString); try { string reply = SynchronousRestFormsRequester.MakeRequest("POST", - m_ServerURI + "/accounts", + uri, reqString); if (reply != string.Empty) { @@ -267,7 +270,7 @@ namespace OpenSim.Services.Connectors } catch (Exception e) { - m_log.DebugFormat("[ACCOUNTS CONNECTOR]: Exception when contacting user account server: {0}", e.Message); + m_log.DebugFormat("[ACCOUNT CONNECTOR]: Exception when contacting user accounts server at {0}: {1}", uri, e.Message); } return false; -- cgit v1.1