public Task StopAsync(CancellationToken cancellationToken) { if (_logger.IsEnabled(LogLevel.Information)) { _logger?.LogInformation("服务开始断开..."); } return(_server.StopAsync(cancellationToken)); }
public Task StopAsync(CancellationToken cancellationToken) { if (_logger.IsEnabled(LogLevel.Information)) { _logger?.LogInformation("服务开始断开..."); } _server.StopAsync(cancellationToken); var serviceRouteManager = _provider.GetService <IServiceRouteManager>(); return(serviceRouteManager.DeregisterAsync()); }