mirror of
https://github.com/xcp-ng/xenadmin.git
synced 2024-11-25 06:16:37 +01:00
CA-180128: Ignoring more exceptions on the connection thread when disruption is expected
Signed-off-by: Mihaela Stoica <mihaela.stoica@citrix.com>
This commit is contained in:
parent
f36c30362f
commit
53e1153801
@ -1278,9 +1278,17 @@ namespace XenAdmin.Network
|
|||||||
XenObjectDownloader.GetEvents(eventNextSession, eventQueue, task.GetCancelled, legacyEventSystem, ref token);
|
XenObjectDownloader.GetEvents(eventNextSession, eventQueue, task.GetCancelled, legacyEventSystem, ref token);
|
||||||
eventsExceptionLogged = false;
|
eventsExceptionLogged = false;
|
||||||
}
|
}
|
||||||
catch (WebException exn)
|
catch (Exception exn)
|
||||||
{
|
{
|
||||||
if (ExpectDisruption && (exn.Status == WebExceptionStatus.KeepAliveFailure || exn.Status == WebExceptionStatus.ConnectFailure))
|
if (!ExpectDisruption)
|
||||||
|
throw;
|
||||||
|
|
||||||
|
log.DebugFormat("Exception (disruption is expected) in XenObjectDownloader.GetEvents: {0}", exn.GetType().Name);
|
||||||
|
|
||||||
|
// ignoring some exceptions when disruption is expected
|
||||||
|
if (exn is XmlRpcIllFormedXmlException ||
|
||||||
|
exn is System.IO.IOException ||
|
||||||
|
(exn is WebException && ((exn as WebException).Status == WebExceptionStatus.KeepAliveFailure || (exn as WebException).Status == WebExceptionStatus.ConnectFailure)))
|
||||||
{
|
{
|
||||||
if (!eventsExceptionLogged)
|
if (!eventsExceptionLogged)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user