This commit is contained in:
@@ -72,11 +72,20 @@ namespace AyaNova.PickList
|
||||
//This may be called internally in *Biz classes who don't have a log of their own
|
||||
if (log == null)
|
||||
log = AyaNova.Util.ApplicationLogging.CreateLogger("PickListFetcher");
|
||||
log.LogInformation("PickList query failed unexpectedly. Query was:");
|
||||
log.LogInformation(q);
|
||||
log.LogInformation(e, "DB Exception");
|
||||
log.LogError("PickList query failed unexpectedly. Query was:");
|
||||
log.LogError(q);
|
||||
log.LogError(e, "DB Exception");
|
||||
throw new System.Exception("PickListFetcher - Query failed see log");
|
||||
}
|
||||
catch (System.Exception e)
|
||||
{
|
||||
//ensure any other type of exception gets surfaced properly
|
||||
//log out the exception and the query
|
||||
log.LogError("PickListFetcher unexpected failure. Query was:");
|
||||
log.LogError(q);
|
||||
|
||||
log.LogError(e, "Exception");
|
||||
throw new System.Exception("PickListFetcher - unexpected failure see log");
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
|
||||
Reference in New Issue
Block a user