/// <summary>Invoked when service is being stopped</summary> public virtual Task Stop() { StoppedCancellationTokenSource.Cancel(); Logger.Info(ErrorCode.RS_ServiceStopping, $"Stopping {this.typeName} grain service"); Status = GrainServiceStatus.Stopped; return(Task.CompletedTask); }
/// <summary>Invoked when service is being stopped</summary> /// <returns>A <see cref="Task"/> representing the work performed.</returns> public virtual Task Stop() { StoppedCancellationTokenSource.Cancel(); Logger.LogInformation( (int)ErrorCode.RS_ServiceStopping, "Stopping {TypeName} grain service", typeName); Status = GrainServiceStatus.Stopped; return(Task.CompletedTask); }