aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorlbsa712008-05-31 20:01:09 +0000
committerlbsa712008-05-31 20:01:09 +0000
commitce234eee376d5af3506399c22519b21ad7540431 (patch)
tree24d251078f003d1b97625ed0d0ac8754690a8aa7 /OpenSim
parent* Propogate OpenSimMain hack to stop mono-addins scanning warnings to the gri... (diff)
downloadopensim-SC_OLD-ce234eee376d5af3506399c22519b21ad7540431.zip
opensim-SC_OLD-ce234eee376d5af3506399c22519b21ad7540431.tar.gz
opensim-SC_OLD-ce234eee376d5af3506399c22519b21ad7540431.tar.bz2
opensim-SC_OLD-ce234eee376d5af3506399c22519b21ad7540431.tar.xz
* Made UpdateUserCurrentRegion a bit more forgiving.
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/Communications/OGS1/OGS1UserServices.cs44
1 files changed, 35 insertions, 9 deletions
diff --git a/OpenSim/Region/Communications/OGS1/OGS1UserServices.cs b/OpenSim/Region/Communications/OGS1/OGS1UserServices.cs
index e0e17df..17b5a06 100644
--- a/OpenSim/Region/Communications/OGS1/OGS1UserServices.cs
+++ b/OpenSim/Region/Communications/OGS1/OGS1UserServices.cs
@@ -205,25 +205,51 @@ namespace OpenSim.Region.Communications.OGS1
205 IList parameters = new ArrayList(); 205 IList parameters = new ArrayList();
206 parameters.Add(param); 206 parameters.Add(param);
207 XmlRpcRequest req = new XmlRpcRequest("update_user_current_region", parameters); 207 XmlRpcRequest req = new XmlRpcRequest("update_user_current_region", parameters);
208 XmlRpcResponse resp = req.Send(m_parent.NetworkServersInfo.UserURL, 3000); 208
209 Hashtable respData = (Hashtable)resp.Value; 209 XmlRpcResponse resp;
210 if (respData.ContainsKey("returnString")) 210
211 try
211 { 212 {
212 if ((string)respData["returnString"] == "TRUE") 213 resp = req.Send(m_parent.NetworkServersInfo.UserURL, 3000);
214 }
215 catch(WebException)
216 {
217 m_log.Warn("[OSG1 USER SERVICES]: Grid not responding. Retrying.");
218
219 try
213 { 220 {
214 m_log.Info("[OSG1 USER SERVICES]: Successfully updated user record"); 221 resp = req.Send(m_parent.NetworkServersInfo.UserURL, 3000);
215 } 222 }
216 else 223 catch (WebException)
217 { 224 {
218 m_log.Error("[OSG1 USER SERVICES]: Error updating user record"); 225 m_log.Warn("[OSG1 USER SERVICES]: Grid not responding. Failed.");
226 return;
219 } 227 }
220 } 228 }
221 else 229
230 if( resp == null )
222 { 231 {
223 m_log.Warn("[OSG1 USER SERVICES]: Error updating user record, Grid server may not be updated."); 232 m_log.Warn("[OSG1 USER SERVICES]: Got no response, Grid server may not be updated.");
233 return;
224 } 234 }
225 235
236 Hashtable respData = (Hashtable)resp.Value;
226 237
238 if (respData == null || !respData.ContainsKey("returnString"))
239 {
240 m_log.Warn("[OSG1 USER SERVICES]: Error updating user record, Grid server may not be updated.");
241 }
242 else
243 {
244 if ((string) respData["returnString"] == "TRUE")
245 {
246 m_log.Info("[OSG1 USER SERVICES]: Successfully updated user record");
247 }
248 else
249 {
250 m_log.Error("[OSG1 USER SERVICES]: Error updating user record");
251 }
252 }
227 } 253 }
228 254
229 public List<AvatarPickerAvatar> GenerateAgentPickerRequestResponse(LLUUID queryID, string query) 255 public List<AvatarPickerAvatar> GenerateAgentPickerRequestResponse(LLUUID queryID, string query)