Assets domain model
The Assets domain owns ION’s customer-scoped asset inventory, classification vocabulary, and import lifecycle. Dataset and automation runs supply asset facts, but the bounded context decides which changes are accepted and records them as authoritative asset, import, and classification history.
The owning team is mdr-ksp-team.
Ubiquitous language
| Term | Meaning in this domain |
|---|---|
| Asset | A customer-scoped inventory item of a known type with identifying properties, classifications, and a source |
| Asset type | The category of an asset: Host, Account, Group, Domain, or Application |
| Classification | A named vocabulary entry defining an asset type, allowed properties, and optional watchlist configuration |
| Active classification | A classification currently applied to an asset |
| Exclusion | A classification recorded as excluded from an asset, preventing automatic re-addition |
| Import set | A single ingestion run with its own lifecycle, progress, and outcome |
| Source | Where an asset or import originated: File, Ui, ScheduledAutomationRun, or ManualAutomationRun |
| Soft deletion | Marking an asset deleted while preserving its identity and audit history |
| Automation run | A scheduled or manual run that ingests assets from a configured data source |
| Watchlist | An external Sentinel projection of classified assets kept in sync by the domain |
| Change log | The audit trail of created, updated, skipped, failed, and deleted asset activity |
Authority and boundaries
| Concern | Authority |
|---|---|
| Asset, import, and classification history | Ordered aggregate event streams |
| Current assets, imports, classifications, and change log | Derived, eventually consistent read models |
| Query and API views | Rebuildable read projection |
| Writes | Aggregate commands |
| Sentinel watchlists | External workspace projection owned by Sentinel; the domain owns the desired state |
A dataset or automation run does not update the read model directly. It enters as commands, is checked against rehydrated aggregates, and produces events only when accepted.
Domain status
The asset, import-set, and classification boundaries are implemented as event-sourced aggregates with state-based CQRS read models and an external Sentinel watchlist projection. See Implementation for how the write model, storage, projections, and integrations are realized.
Static domain model
This page describes the static structure of the Assets domain: its aggregates, entities, invariants, states, commands, and events. It is intended to be technology-agnostic — see Implementation for how it is realized on Cosmos DB, Azure SQL, and the external watchlist API.
Aggregate roots
| Aggregate root | Identity and responsibility | Held state | Implemented behavior |
|---|---|---|---|
AssetAggregate | One asset stream, scoped to a customer | Asset identity, source, classifications, exclusions, comment, and type-specific properties | Create, update changed attributes, skip an automation result, or soft-delete |
ImportSetAggregate | One import-set stream, scoped to a customer | Import source, progress, skipped records, automation reference, and outcome | Enforces Queued → InProgress → Completed, with failure from Queued |
ClassificationAggregate | One classification, identified by name and shared across customers | Description, asset type, allowed properties, and optional watchlist configuration | Create or emit attribute-specific update events |
Current-state asset, import-set, classification, and change-log records are read projections, not children of the aggregates.
Entities and value objects
Asset value structure
| Asset type | Accepted identifying properties |
|---|---|
Host | Device FQDN, hostname, device ID, or one or more IP addresses |
Account | Account name, user principal name, or user ID |
Group | Group name or group SID |
Domain | Domain name |
Application | Application name |
Every asset also has a customer, import-set reference, name, source, active
classifications, optional exclusions, and optional comment. Sources are File,
Ui, ScheduledAutomationRun, and ManualAutomationRun.
Domain ERD
Lifecycle and states
Import-set lifecycle
The dynamic walkthrough of these transitions lives in Flows.
Invariants and policies
Import-set lifecycle rules
ImportSetAggregate rejects commands outside the transitions above. Queueing is
valid only for a new stream; chunk recording and completion require InProgress.
Asset ingestion invariants
- A non-empty imported record has at least one known classification.
- Each classification has the same asset type as the record.
- At least one property required by each classification is populated.
- A classification cannot be both active and excluded.
- Asset type and operation names are case-sensitive enum values.
- Duplicate resulting asset names in one dataset are skipped.
- Invalid IP addresses are reported; the pipeline skips any row with a validation issue.
- An import without an asset ID matches the latest stream in the customer scope by asset name; a UI command with an asset ID must find that stream.
- During scheduled or manual automation, an existing asset is skipped when all incoming classifications are already excluded.
Soft deletion
Assets are not removed from the event history or the current-state read model.
IngestIonAssetcarries operationDeleteand a deletion reason.- The aggregate rejects deletion when no active classifications remain.
IonAssetDeletedrecords the reason.- All active classifications move to exclusions.
- Active classifications are cleared.
- The read projection and change log reflect the committed event.
This preserves identity and audit history while preventing excluded automation from immediately restoring the asset.
Commands
| Boundary | Commands |
|---|---|
| Aggregate writes | QueueImport, FailImport, InitiateImport, RecordImportChunkInfo, CompleteImport, IngestIonAsset, UpsertIonClassification |
| Ingestion orchestration | RetrieveDataset, EnrichDataChunk |
| Automation | RunAutomations |
| Watchlists | SyncWatchlists, SyncWatchlist, WatchlistOperation |
Events
| Aggregate | Events |
|---|---|
| Import set | ImportQueued, ImportFailed, ImportInitiated, ImportRecordedChunkInfo, ImportCompleted |
| Asset lifecycle | IonAssetCreated, IonAssetSkipped, IonAssetDeleted |
| Asset changes | Import-set ID, source, name, classifications, exclusions, comment, FQDN, device ID, hostname, IP addresses, account name, UPN, user ID, group name, group SID, domain name, and application name updated |
| Classification | Created; description, asset type, asset properties, or watchlist configuration updated |
See the V3 event model for the common envelope.