Beispiel #1
0
        protected override async Task OnCloseAsync(
            CancellationToken cancellationToken)
        {
            var payload = new StatefulServiceEventPayloadOnShutdown(false);

            await this.serviceEvents.NotifyShutdownAsync(payload, cancellationToken);
        }
Beispiel #2
0
        protected override void OnAbort()
        {
            var payload = new StatefulServiceEventPayloadOnShutdown(false);

            this.serviceEvents.NotifyShutdownAsync(payload, default).GetAwaiter().GetResult();
        }