protected override void OnContinue() { try { _log.Info("[Topshelf] Pausing service"); _serviceHandle.Continue(this); } catch (Exception ex) { _log.Fatal("The service did not shut down gracefully", ex); throw; } finally { _log.Info("[Topshelf] Paused"); } }
protected override void OnContinue() { try { _log.Info("[Topshelf] Resuming service"); if (!_serviceHandle.Continue(this)) { throw new TopshelfException("The service did not continue successfully (returned false)."); } _log.Info("[Topshelf] Resumed"); } catch (Exception ex) { _log.Fatal("The service did not resume successfully", ex); throw; } }
public bool Continue(HostControl hostControl) { return(_serviceHandle.Continue(hostControl)); }
bool ServiceHandle.Continue(HostControl hostControl) { return(_service.Continue(_hostControl)); }
bool ServiceHandle.Continue(HostControl hostControl) { var control = new AppDomainHostControl(this); return(_service.Continue(control)); }