Table of Contents

Class JobCntrlRuntime

Namespace
Tlabs.JobCntrl.Intern
Assembly
Tlabs.JobCntrl.dll

Job control execution runtime.

public sealed class JobCntrlRuntime : IJobControl, IDisposable
Inheritance
JobCntrlRuntime
Implements
Inherited Members
Extension Methods

Constructors

JobCntrlRuntime(IJobControlCfgLoader)

Ctor from cfgLoader.

public JobCntrlRuntime(IJobControlCfgLoader cfgLoader)

Parameters

cfgLoader IJobControlCfgLoader

JobCntrlRuntime(IJobControlCfgLoader, IStarterCompletionPersister?)

Ctor from cfgLoader and starterCompletionPersister.

public JobCntrlRuntime(IJobControlCfgLoader cfgLoader, IStarterCompletionPersister? starterCompletionPersister)

Parameters

cfgLoader IJobControlCfgLoader
starterCompletionPersister IStarterCompletionPersister

Properties

CompletionPersister

Returns the IStarterCompletionPersister used to persist activator completion data.

public IStarterCompletionPersister? CompletionPersister { get; }

Property Value

IStarterCompletionPersister

ConfigLoader

Returns the IJobControlCfgLoader used by the JobControl to load it's configuration.

public IJobControlCfgLoader ConfigLoader { get; }

Property Value

IJobControlCfgLoader

CurrentJobActivationCount

Current number of (starter) activation(s).

public int CurrentJobActivationCount { get; }

Property Value

int

FullCompletion

Returns a Task that completes once CurrentJobActivationCount is 0>.

public Task FullCompletion { get; }

Property Value

Task

Jobs

Dictionary of runtime IJob(s).

public IReadOnlyDictionary<string, IJob> Jobs { get; }

Property Value

IReadOnlyDictionary<string, IJob>

MasterModels

Master model's configuration.

public IMasterCfg MasterModels { get; }

Property Value

IMasterCfg

Starters

Dictionary of runtime IStarter(s).

public IReadOnlyDictionary<string, IStarter> Starters { get; }

Property Value

IReadOnlyDictionary<string, IStarter>

Methods

Dispose()

public void Dispose()

Init()

Initializes the IJobControl runtime by loading its configuration.

public void Init()

Exceptions

JobCntrlException

thrown when JobControl was already started

Start()

Load and start activating configured starter(s) and job(s).

public void Start()

Exceptions

JobCntrlException

thrown when JobControl was already started or not initialized.

Stop()

Stop executing any starter(s) and jobs(s) and discards any configuration.

public void Stop()

Remarks

It is required to invoke Init() before re-starting the runtime.