BackgroundService.ExecuteAsync(CancellationToken) BackgroundService.ExecuteAsync(CancellationToken) BackgroundService.ExecuteAsync(CancellationToken) Method

Definition

This method is called when the IHostedService starts. The implementation should return a task that represents the lifetime of the long running operation(s) being performed.

protected abstract System.Threading.Tasks.Task ExecuteAsync (System.Threading.CancellationToken stoppingToken);
abstract member ExecuteAsync : System.Threading.CancellationToken -> System.Threading.Tasks.Task
Protected MustOverride Function ExecuteAsync (stoppingToken As CancellationToken) As Task

Parameters

Returns

A Task that represents the long running operations.

Applies to