Requirements

Application

ConfigDaemon.StorageAccessibility

Files persisted by ConfigDaemon shall be writable by ConfigDaemon only.

ConfigDaemon.StorageFailure

In case file system is not accessible for ConfigDaemon application at startup or any other failure leads to parameter data model populated incompletely, ConfigDaemon application shall not offer any services.

ConfigDaemon.Lifecycle

{{ConfigDaemon}} shall implement {{Initialize()}} and {{Run()}} functions in order to be managed by {{LifecycleManager}}.

ApplicationStages

ConfigDaemon.InitializePlugins

The {{ConfigDaemon}} shall setup {{Plugins}} during the execution of {{ConfigDaemon::Initialize()}}. The setup consists of the following steps: * Create {{Plugins}} by using {{PluginCollector}}. * Store created {{Plugins}} in internall collection. * Call the {{Initialize()}} function exactly once for each {{Plugin}} in the collection.

ConfigDaemon.InitializeService

The {{ConfigDaemon}} shall create and initialize {{InternalConfigProviderService}} service during the execution of {{ConfigDaemon::Initialize()}}.

ConfigDaemon.RunPlugins

The {{ConfigDaemon}} shall call the {{Run()}} function exactly once for each {{Plugin}} in the collection during the execution of {{ConfigDaemon::Run()}}.

ConfigDaemon.RunService

The {{ConfigDaemon}} shall offer {{InternalConfigProviderService}} service during the execution of {{ConfigDaemon::Run()}}.

ConfigDaemon.RunIdle

Following Run activity finalization, {{ConfigDaemon}} shall remain locked in an idle state until {{stop_token}} is modified.

ConfigDaemon.RunShutdown

{{ConfigDaemon}} shall process {{stop_token}} to interrupt any waiting and initiate the application shutdown.

ConfigDaemon.ShutdownPlugins

The {{ConfigDaemon}} shall call the {{Deinitialize()}} function exactly once for each {{Plugin}} in the collection during the execution of {{ConfigDaemon}} shutdown.

ConfigDaemon.ShutdownService

The {{ConfigDaemon}} shall stop offering {{InternalConfigProviderService}} during the execution of {{ConfigDaemon}} shutdown.

ParameterSetService

ConfigDaemon.ParameterSetServiceOffering

Component shall offer a Parameter Set Service, which allows to query a Parameter Set with its Parameter Set Qualifier from the Data Model.

DataModel

ConfigDaemon.DataModel

DataModel is a collection of Parameter Sets, which can be added by the Plugins.

ConfigDaemon.ParameterSets

Parameters are grouped into Parameter Sets, which enables clients to obtain an aggregated state of all values within that set.

DataModel Integrity

ConfigDaemon.DefaultDataModelLoading

When {{ConfigDaemon}} is initialized, it shall load the Data Model from {{Default Parameter Set Collection file}} if {{Parameter Set Collection file}} is not available or its integrity is not successfully verified.

ConfigDaemon.ActualDataModelLoading

When {{ConfigDaemon}} is initialized, it shall load the Data Model from {{Parameter Set Collection file}} if available and its integrity is verified.

ConfigDaemon.FileAccess

Files persisted by {{ConfigDaemon}} shall be readable by {{ConfigDaemon}} and priviledged user applications and writable by {{ConfigDaemon}} only.

ConfigDaemon.DataModelChecksum

A checksum shall be calculated for the content of {{Parameter Set Collection file}} stored persistently to protect it from corruption.

ConfigDaemon.DataModelVerification

The checksum protecting {{Parameter Set Collection file}} shall be evaluated during startup of {{ConfigDaemon}} prior to loading of {{Parameter Set Collection file}} contents into the {{Data Model}} to ensure that no corruption of data has occurred.

ConfigDaemon.StoredQualifier

Every {{Parameter Set Qualifier}} loaded from the {{Parameter Set Collection file}} shall have the value {{QUALIFYING}}.

SupportedParameterTypes

ConfigDaemon.PrimitiveTypes

Following primitive parameter types shall be supported: * {{bool}} * {{sint8}} * {{sint16}} * {{sint32}} * {{sint64}} * {{uint8}} * {{uint16}} * {{uint32}} * {{uint64}} * {{float32}} * {{float64}}

Note: This only applies to the Daemon Application. Plugins may also only support a subset of the types.

ConfigDaemon.ComplexTypes

Following complex parameter types shall be supported: * One dimensional arrays of {{SupportedParameterTypes::PrimitiveTypes}} * Two dimensional arrays of {{SupportedParameterTypes::PrimitiveTypes}}

Note: This only applies to the Daemon Application. Plugins may also only support a subset of the types.

ConfigDaemon.ParameterSetQualifier

The ParameterSet qualifier shall be restricted to one of the following states: {{DEFAULT}},{{QUALIFYING}}, {{QUALIFIED}}, {{UNQUALIFIED}} or {{MODIFIED}}. Any other value is invalid.

Plugins

ConfigDaemon.PluginResponsibility

{{Plugin}} components are responsible for populating or modifing the contents of the {{ParameterSetCollection}}.

ConfigDaemon.PluginSingleParametersType

{{Plugin}} shall process parameters of only one kind, e.g. coding or calibration or custom type of parameters.

ConfigDaemon.PluginCreation

{{Plugin}} shall register its own {{PluginCreator}} in {{PluginCollector}} in order to be created.

ConfigDaemon.PluginInitialization

{{Plugin}} shall implement the {{Initialize()}} function in a non-blocking manner.

ConfigDaemon.PluginRun

{{Plugin}} recieves handles to the {{ParameterSetCollection}} and to the {{InternalConfigProviderService}} within {{Run}} method. This handles should be used to update the database and notify clients about parameter and qualifier changes.