diff options
author | Justin Clark-Casey (justincc) | 2012-02-07 21:40:28 +0000 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2012-02-07 21:40:28 +0000 |
commit | 1f402fdf5e8ef53a07f98c4447946805791d26bc (patch) | |
tree | d7a0ea0ee0538e0a14bb69dd2e76cf9ac43e34b5 /OpenSim/Services/Connectors/UserAccounts | |
parent | Add TestAddTaskInventoryItem() (diff) | |
download | opensim-SC_OLD-1f402fdf5e8ef53a07f98c4447946805791d26bc.zip opensim-SC_OLD-1f402fdf5e8ef53a07f98c4447946805791d26bc.tar.gz opensim-SC_OLD-1f402fdf5e8ef53a07f98c4447946805791d26bc.tar.bz2 opensim-SC_OLD-1f402fdf5e8ef53a07f98c4447946805791d26bc.tar.xz |
Add url to logging if SynchronousRestFormsRequester.MakRequest() throws an exception in service connectors
Diffstat (limited to 'OpenSim/Services/Connectors/UserAccounts')
-rw-r--r-- | OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs | 15 |
1 files changed, 9 insertions, 6 deletions
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 | |||
138 | 138 | ||
139 | string reply = string.Empty; | 139 | string reply = string.Empty; |
140 | string reqString = ServerUtils.BuildQueryString(sendData); | 140 | string reqString = ServerUtils.BuildQueryString(sendData); |
141 | string uri = m_ServerURI + "/accounts"; | ||
141 | // m_log.DebugFormat("[ACCOUNTS CONNECTOR]: queryString = {0}", reqString); | 142 | // m_log.DebugFormat("[ACCOUNTS CONNECTOR]: queryString = {0}", reqString); |
142 | try | 143 | try |
143 | { | 144 | { |
144 | reply = SynchronousRestFormsRequester.MakeRequest("POST", | 145 | reply = SynchronousRestFormsRequester.MakeRequest("POST", |
145 | m_ServerURI + "/accounts", | 146 | uri, |
146 | reqString); | 147 | reqString); |
147 | if (reply == null || (reply != null && reply == string.Empty)) | 148 | if (reply == null || (reply != null && reply == string.Empty)) |
148 | { | 149 | { |
@@ -152,7 +153,7 @@ namespace OpenSim.Services.Connectors | |||
152 | } | 153 | } |
153 | catch (Exception e) | 154 | catch (Exception e) |
154 | { | 155 | { |
155 | m_log.DebugFormat("[ACCOUNT CONNECTOR]: Exception when contacting accounts server: {0}", e.Message); | 156 | m_log.DebugFormat("[ACCOUNT CONNECTOR]: Exception when contacting user accounts server at {0}: {1}", uri, e.Message); |
156 | } | 157 | } |
157 | 158 | ||
158 | List<UserAccount> accounts = new List<UserAccount>(); | 159 | List<UserAccount> accounts = new List<UserAccount>(); |
@@ -206,11 +207,12 @@ namespace OpenSim.Services.Connectors | |||
206 | { | 207 | { |
207 | string reply = string.Empty; | 208 | string reply = string.Empty; |
208 | string reqString = ServerUtils.BuildQueryString(sendData); | 209 | string reqString = ServerUtils.BuildQueryString(sendData); |
210 | string uri = m_ServerURI + "/accounts"; | ||
209 | // m_log.DebugFormat("[ACCOUNTS CONNECTOR]: queryString = {0}", reqString); | 211 | // m_log.DebugFormat("[ACCOUNTS CONNECTOR]: queryString = {0}", reqString); |
210 | try | 212 | try |
211 | { | 213 | { |
212 | reply = SynchronousRestFormsRequester.MakeRequest("POST", | 214 | reply = SynchronousRestFormsRequester.MakeRequest("POST", |
213 | m_ServerURI + "/accounts", | 215 | uri, |
214 | reqString); | 216 | reqString); |
215 | if (reply == null || (reply != null && reply == string.Empty)) | 217 | if (reply == null || (reply != null && reply == string.Empty)) |
216 | { | 218 | { |
@@ -220,7 +222,7 @@ namespace OpenSim.Services.Connectors | |||
220 | } | 222 | } |
221 | catch (Exception e) | 223 | catch (Exception e) |
222 | { | 224 | { |
223 | m_log.DebugFormat("[ACCOUNT CONNECTOR]: Exception when contacting user account server: {0}", e.Message); | 225 | m_log.DebugFormat("[ACCOUNT CONNECTOR]: Exception when contacting user accounts server at {0}: {1}", uri, e.Message); |
224 | } | 226 | } |
225 | 227 | ||
226 | Dictionary<string, object> replyData = ServerUtils.ParseXmlResponse(reply); | 228 | Dictionary<string, object> replyData = ServerUtils.ParseXmlResponse(reply); |
@@ -241,11 +243,12 @@ namespace OpenSim.Services.Connectors | |||
241 | private bool SendAndGetBoolReply(Dictionary<string, object> sendData) | 243 | private bool SendAndGetBoolReply(Dictionary<string, object> sendData) |
242 | { | 244 | { |
243 | string reqString = ServerUtils.BuildQueryString(sendData); | 245 | string reqString = ServerUtils.BuildQueryString(sendData); |
246 | string uri = m_ServerURI + "/accounts"; | ||
244 | // m_log.DebugFormat("[ACCOUNTS CONNECTOR]: queryString = {0}", reqString); | 247 | // m_log.DebugFormat("[ACCOUNTS CONNECTOR]: queryString = {0}", reqString); |
245 | try | 248 | try |
246 | { | 249 | { |
247 | string reply = SynchronousRestFormsRequester.MakeRequest("POST", | 250 | string reply = SynchronousRestFormsRequester.MakeRequest("POST", |
248 | m_ServerURI + "/accounts", | 251 | uri, |
249 | reqString); | 252 | reqString); |
250 | if (reply != string.Empty) | 253 | if (reply != string.Empty) |
251 | { | 254 | { |
@@ -267,7 +270,7 @@ namespace OpenSim.Services.Connectors | |||
267 | } | 270 | } |
268 | catch (Exception e) | 271 | catch (Exception e) |
269 | { | 272 | { |
270 | m_log.DebugFormat("[ACCOUNTS CONNECTOR]: Exception when contacting user account server: {0}", e.Message); | 273 | m_log.DebugFormat("[ACCOUNT CONNECTOR]: Exception when contacting user accounts server at {0}: {1}", uri, e.Message); |
271 | } | 274 | } |
272 | 275 | ||
273 | return false; | 276 | return false; |