if a SynchronousRestObjectRequester request fails, then unless it's due to a 404, log the exception for diagnostic purposes
This is instead of logging "Invalid XML" for all failures, even if they weren't a result of invalid xml. A default TReponse is returned in the event of a 404, which is the same behaviour as previously.bulletsim
parent
e434ba5e8e
commit
938b4f8bf8
|
@ -987,6 +987,17 @@ namespace OpenSim.Framework
|
|||
|
||||
}
|
||||
}
|
||||
catch (WebException e)
|
||||
{
|
||||
HttpWebResponse hwr = (HttpWebResponse)e.Response;
|
||||
|
||||
if (hwr != null && hwr.StatusCode == HttpStatusCode.NotFound)
|
||||
return deserial;
|
||||
else
|
||||
m_log.ErrorFormat(
|
||||
"[SynchronousRestObjectRequester]: WebException {0} {1} {2} {3}",
|
||||
requestUrl, typeof(TResponse).ToString(), e.Message, e.StackTrace);
|
||||
}
|
||||
catch (System.InvalidOperationException)
|
||||
{
|
||||
// This is what happens when there is invalid XML
|
||||
|
|
Loading…
Reference in New Issue