diff --git a/src/Microsoft.SqlTools.ServiceLayer/DisasterRecovery/RestoreOperation/RestoreDatabaseTaskDataObject.cs b/src/Microsoft.SqlTools.ServiceLayer/DisasterRecovery/RestoreOperation/RestoreDatabaseTaskDataObject.cs index 3e9ea00e..7e2fda66 100644 --- a/src/Microsoft.SqlTools.ServiceLayer/DisasterRecovery/RestoreOperation/RestoreDatabaseTaskDataObject.cs +++ b/src/Microsoft.SqlTools.ServiceLayer/DisasterRecovery/RestoreOperation/RestoreDatabaseTaskDataObject.cs @@ -316,6 +316,7 @@ namespace Microsoft.SqlTools.ServiceLayer.DisasterRecovery.RestoreOperation } catch(Exception ex) { + Logger.Write(LogLevel.Normal, $"Failed to execute restore task. error: {ex.Message}"); throw ex; } finally diff --git a/src/Microsoft.SqlTools.ServiceLayer/LanguageServices/ConnectedBindingQueue.cs b/src/Microsoft.SqlTools.ServiceLayer/LanguageServices/ConnectedBindingQueue.cs index c1d23ca2..1c4fc414 100644 --- a/src/Microsoft.SqlTools.ServiceLayer/LanguageServices/ConnectedBindingQueue.cs +++ b/src/Microsoft.SqlTools.ServiceLayer/LanguageServices/ConnectedBindingQueue.cs @@ -125,7 +125,14 @@ namespace Microsoft.SqlTools.ServiceLayer.LanguageServices { if (bindingContext.BindingLock.WaitOne(millisecondsTimeout)) { - bindingContext.ServerConnection.Connect(); + try + { + bindingContext.ServerConnection.Connect(); + } + catch + { + //TODO: remove the binding context? + } } } }