Class TaskReporter
Type handling reporting of events related to a single task.
Inherited Members
Namespace: Cognite.Extractor.Utils.Unstable.Tasks
Assembly: ExtractorUtils.dll
Syntax
public class TaskReporter : BaseErrorReporter
Constructors
| Edit this page View SourceTaskReporter(string, IIntegrationSink)
Constructor.
Declaration
public TaskReporter(string taskName, IIntegrationSink sink)
Parameters
Type | Name | Description |
---|---|---|
string | taskName | Name of the task, must be unique. |
IIntegrationSink | sink | Sink for task events. |
Methods
| Edit this page View SourceNewError(ErrorLevel, string, string?, DateTime?)
Create a new extractor error belonging to this reporter.
Declaration
public override ExtractorError NewError(ErrorLevel level, string description, string? details = null, DateTime? now = null)
Parameters
Type | Name | Description |
---|---|---|
ErrorLevel | level | Error level. |
string | description | Short error description. |
string | details | Long error details. |
DateTime? | now | Optional current timestamp. |
Returns
Type | Description |
---|---|
ExtractorError |
Overrides
| Edit this page View SourceReportEnd(TaskUpdatePayload?, DateTime?)
Report that this task has ended.
Declaration
public void ReportEnd(TaskUpdatePayload? update = null, DateTime? timestamp = null)
Parameters
Type | Name | Description |
---|---|---|
TaskUpdatePayload | update | Message and context tied to task run |
DateTime? | timestamp |
ReportStart(TaskUpdatePayload?, DateTime?)
Report that this task has started.
Declaration
public void ReportStart(TaskUpdatePayload? update = null, DateTime? timestamp = null)
Parameters
Type | Name | Description |
---|---|---|
TaskUpdatePayload | update | Message and context tied to task run |
DateTime? | timestamp |