Skip to main content

Operator Management Service — Domain Model

Status: populated Owner: Platform Engineering Last updated: 2026-04-18 Companion: SERVICE_OVERVIEW · DATA_MODEL · EVENT_SCHEMAS

1. Aggregates

Operator (root)

Represents a carrier SMPP connection endpoint with its full configuration.

FieldTypeNotes
operatorIdOperatorId (UUIDv4 branded)Aggregate identity
nameOperatorName (VO)Human-readable label, unique
hostHostname (VO)SMPP server hostname/IP
portPort (VO)SMPP port (1–65535)
systemIdSystemId (VO)SMPP bind system_id
systemTypestringSMPP system_type (optional)
bindTypeBindType enumTRANSCEIVER, TRANSMITTER, RECEIVER
tpsLimitTpsLimit (VO)Max transactions/second
burstWindowBurstWindow (VO)Sliding window in ms
statusOperatorStatus enumACTIVE, INACTIVE, SUSPENDED
healthStateHealthState enumHEALTHY, DEGRADED, UNHEALTHY, UNKNOWN
deletedAtInstant | nullSoft-delete timestamp
createdByAdminIdWho created
updatedByAdminIdWho last updated

Note: SMPP password is not a field on this aggregate. It lives exclusively in Vault.

RoutingRule (root)

Maps a destination prefix to an operator with priority and cost.

FieldTypeNotes
ruleIdRuleId (UUIDv4)
prefixDestinationPrefix (VO)E.164 prefix
mcc / mncstringOptional PLMN codes
operatorIdOperatorIdFK to Operator
prioritynumberLower = higher priority
weightnumberLoad-balance weight
costPerSegmentMoney (VO)Wholesale cost
activeboolean

2. Value Objects

VOInvariant
OperatorName1–128 chars, unique
HostnameValid hostname or IPv4; no scheme prefix
PortInteger 1–65535
SystemId1–16 chars
DestinationPrefixMatches ^\+[0-9]{1,15}$
MoneyNon-negative decimal(18,6); ISO 4217 currency

3. State Machines

Operator status

INACTIVE → ACTIVE
ACTIVE → SUSPENDED
ACTIVE → INACTIVE
SUSPENDED → ACTIVE
ANY → soft-deleted (deleted_at set)

Operator health state

UNKNOWN → HEALTHY (first successful bind)
HEALTHY → DEGRADED (error rate > 5% for 60 s)
DEGRADED → UNHEALTHY (error rate > 20% for 60 s or bind lost)
UNHEALTHY → HEALTHY (bind restored, error rate < 1% for 30 s)
DEGRADED → HEALTHY (error rate < 1% for 30 s)

4. Domain Events

See EVENT_SCHEMAS for full schemas.

EventTrigger
operator.config.created.v1New operator created
operator.config.updated.v1Operator fields or rules changed
operator.config.deleted.v1Soft-delete
operator.health.v1Health state transition

5. Domain Services

ServicePurpose
OperatorCredentialsServiceRead/write SMPP credentials in Vault exclusively
DuplicateOperatorGuardEnforces unique (host, port, systemId) before INSERT
HealthStateReducerReduces smpp-connector health event to authoritative health state
RoutingRuleConflictCheckerDetects prefix overlap before rule INSERT

6. Domain Errors

ErrorCauseHTTP
DuplicateOperatorErrorSame (host, port, systemId) exists409
OperatorNotFoundErrorUnknown or soft-deleted404
VaultWriteErrorVault unavailable503
PrefixConflictErrorPrefix overlaps existing active rule409
TpsLimitInvalidErrormaxTps < 1 or burstMultiplier < 1.0400