Interface IWorkScheduler
Schedules work for execution.
Namespace: DNVGL.One.Compute.Scheduling.WorkScheduling
Assembly: DNVGL.One.Compute.Scheduling.dll
Syntax
public interface IWorkScheduler
Properties
View SourceTelemetryInstrumentationKey
Gets or sets the instrumentation key for use by a telemetry client.
Declaration
string TelemetryInstrumentationKey { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String | The telemetry client instrumentation key. |
Methods
View SourceInitializeJob(Job)
Do backend specific job initialization.
Declaration
void InitializeJob(Job job)
Parameters
| Type | Name | Description |
|---|---|---|
| Job | job | The job. |
OverrideWorkerStorageConnectionString(String)
Worker default is to establish the connection to the storage via deployment configuration but setting this allows override over command line. Optional storage connection string to pass to worker.
Declaration
void OverrideWorkerStorageConnectionString(string storageConnectionString)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | storageConnectionString | The storage connection string. |
ScheduleWork(Job, String, IEnumerable<WorkUnit>, SchedulingOptions, CancellationToken)
Schedules the work.
Declaration
IWorkMonitor ScheduleWork(Job job, string batchId, IEnumerable<WorkUnit> workBatch, SchedulingOptions options, CancellationToken cancellationToken)
Parameters
| Type | Name | Description |
|---|---|---|
| Job | job | The job. |
| System.String | batchId | The batch identifier. |
| IEnumerable<WorkUnit> | workBatch | The work batch. |
| SchedulingOptions | options | The options. |
| CancellationToken | cancellationToken | The cancellation token. |
Returns
| Type | Description |
|---|---|
| IWorkMonitor | Work monitor. |
TerminateJob(String)
Terminates the job. If work is ongoing, it will be cancelled.
Declaration
void TerminateJob(string jobId)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | jobId | The job identifier. |