63 lines
2.2 KiB
Markdown
63 lines
2.2 KiB
Markdown
# Runtime event mixing architecture
|
|
|
|
The runtime mixing engine is source-neutral. Source-specific behavior is contributed through four extension points:
|
|
|
|
1. `RuntimeEventSemantics` classifies an event and supplies semantic lifecycle normalization.
|
|
2. `RuntimeEventMixingRuleProvider` supplies source/domain-specific rules.
|
|
3. `RuntimeEventCompatibilityPolicy` validates candidate pairs after broad grouping.
|
|
4. `RuntimeEventFusionPolicy` enriches or transforms the retained primary event.
|
|
|
|
## Generic classifications
|
|
|
|
`RuntimeEventSourceProfile` stores opaque classifications rather than domain-specific enums. The built-in keys are:
|
|
|
|
- `sourceFamily`
|
|
- `sourceRole`
|
|
- `representation`
|
|
- `extractionCode`
|
|
|
|
The common engine does not interpret their values. A tachograph adapter currently publishes values such as `TACHOGRAPH`, `DRIVER_CARD`, `VEHICLE_UNIT`, `DATABASE`, and `FILE_SESSION`. Another source family can publish different values without changing `RuntimeEventMixingRule` or `RuntimeEventMixingService`.
|
|
|
|
## Generic rule structure
|
|
|
|
A rule consists of:
|
|
|
|
- channel and event-domain/type/lifecycle filters;
|
|
- an equivalence-key type;
|
|
- a primary `RuntimeEventSelector`;
|
|
- a secondary `RuntimeEventSelector`;
|
|
- optional `RuntimeEventPairConstraint` values, such as equal `sourceRole`;
|
|
- a compatibility-policy id;
|
|
- a fusion-policy id;
|
|
- output roles and audit text.
|
|
|
|
Source-specific values belong only in a source-specific `RuntimeEventMixingRuleProvider`.
|
|
|
|
## Tachograph plugin
|
|
|
|
The tachograph implementation is isolated in:
|
|
|
|
- `RuntimeTachographEventSemantics`
|
|
- `RuntimeTachographEventMixingRuleProvider`
|
|
- `RuntimeTachographEvidenceCompatibilityPolicy`
|
|
- `RuntimeTachographActivityCompatibilityPolicy`
|
|
- `RuntimeTachographVehicleIdentityFusionPolicy`
|
|
|
|
The generic classes do not import tachograph source-role or representation types.
|
|
|
|
## Diagnostics
|
|
|
|
Diagnostics are now emitted as generic maps:
|
|
|
|
- `sourceFamilyCounts`
|
|
- `sourceRoleCounts`
|
|
- `representationCounts`
|
|
|
|
This replaces tachograph-specific scalar counters in the event-mixing module metadata.
|
|
|
|
## Modes
|
|
|
|
- `OFF` disables all providers.
|
|
- `FULL` enables all providers that support the mode.
|
|
- The tachograph provider continues to accept the legacy `TACHOGRAPH_SAME_SOURCE` value.
|