Platform Service (StellaOps.Platform.WebService)

Purpose

Provide a single, deterministic aggregation layer for cross-service UX workflows (health, quotas, onboarding, preferences, global search) so the Console UI and CLI do not fan out to multiple modules directly.

Non-goals

Responsibilities

API surface (v1)

Health aggregation

Quota aggregation

Onboarding

Preferences

Metadata

Localization

Release Orchestrator compatibility

Notification admin routing

Synthetic compatibility harnesses

QA fixture readback

Advanced assurance case summary

Advanced assurance scenario transactions

API surface (v2)

Global context

The context region/environment PUT routes are setup-admin convergence APIs for operator-managed installs. They let setup scripts and local lab preparation add real deployment regions and environments without direct SQL.

PUT /api/v2/context/regions/{regionId} accepts:

{
  "displayName": "Local Lab",
  "sortOrder": 5,
  "enabled": true
}

PUT /api/v2/context/environments/{environmentId} accepts:

{
  "regionId": "local-lab",
  "environmentType": "development",
  "displayName": "Customer TEST Lab",
  "sortOrder": 6,
  "enabled": true
}

Both routes require platform.context.write. Region IDs and environment IDs are normalized to lower-case route IDs. Environment upsert requires the referenced region to already exist. Validation failures use deterministic error codes such as region_id_required, region_not_found, environment_id_required, environment_type_required, and environment_type_invalid.

Releases read model

Topology inventory read model

Security read model

Integrations read model

Analytics (SBOM lake)

NIS2 telemetry effectiveness

Crypto provider catalog admin (SPRINT_20260503_008)

Legacy alias compatibility (/api/v1/*)

Data model

Startup migration convergence

Dependencies

Runtime boundary policy

Security and scopes

Determinism and offline posture

Analytics ingestion configuration

Analytics ingestion runs inside the Platform WebService and subscribes to Scanner, Concelier, and Attestor streams. Configure ingestion with Platform:AnalyticsIngestion:

Platform:
  AnalyticsIngestion:
    Enabled: true
    PostgresConnectionString: "" # optional; defaults to Platform:Storage
    AllowedTenants: ["tenant-a"]
    Streams:
      ScannerStream: "orchestrator:events"
      ConcelierObservationStream: "concelier:advisory.observation.updated:v1"
      ConcelierLinksetStream: "concelier:advisory.linkset.updated:v1"
      AttestorStream: "attestor:events"
      StartFromBeginning: false
    Cas:
      RootPath: "/var/lib/stellaops/cas"
      DefaultBucket: "attestations"
    Attestations:
      BundleUriTemplate: "bundle:{digest}"

BundleUriTemplate supports {digest} and {hash} placeholders. The bundle: scheme maps to cas://<DefaultBucket>/{digest} by default. Verify offline bundles with stella bundle verify before ingestion.

Analytics maintenance configuration

Analytics rollups + materialized view refreshes are driven by PlatformAnalyticsMaintenanceService when analytics storage is configured.
Use BackfillDays to recompute recent rollups on the first maintenance run (set to 0 to disable).

Platform:
  Storage:
    PostgresConnectionString: "Host=...;Database=...;Username=...;Password=..."
  AnalyticsMaintenance:
    Enabled: true
    RunOnStartup: true
    IntervalMinutes: 1440
    ComputeDailyRollups: true
    RefreshMaterializedViews: true
    BackfillDays: 7

Observability

Gateway exposure

The Platform Service is exposed via Gateway and registered through Router discovery. It does not expose direct ingress outside Gateway in production.

Setup Wizard

The Platform Service owns the installation-scoped setup wizard used by /setup-wizard/wizard for first-run control-plane bootstrap and later reconfiguration checks.

Current runtime behavior:

API surface (v1)

Sessions

Session payloads distinguish:

Steps

Definitions

Setup step identifiers

Step IDTitleRequiredDepends OnNotes
databasePostgreSQL DatabaseYes-Probe verifies reachability. Apply records convergence against the current runtime connection.
valkeyValkey / Redis SetupYes-Probe verifies cache reachability. Apply records convergence against the current runtime connection.
migrationsDatabase MigrationsYesdatabaseProbe reports pending migration state. Apply runs the migration-admin path against the canonical Platform and ReleaseOrchestrator registry modules and re-validates convergence.
adminAdmin BootstrapYesmigrationsProbe validates bootstrap prerequisites. Apply ensures the bootstrap admin exists.
cryptoCryptographyYesadminProbe validates the requested regional crypto profile and emits soft warnings for unmet NIS2/DORA/CRA prerequisites. Apply records the canonical Crypto:* and Compliance:* installation defaults.
sourcesAdvisory & VEX SourcesNoadminProbe validates mirror or manual source selections. Apply persists source enablement through Concelier and schedules initial aggregation for newly enabled sources.

Legacy aliases accepted during the compatibility window:

Former tenant-onboarding steps such as vault, scm, registry, notify, environments, agents, telemetry, llm, and settingsstore are no longer valid setup targets. Platform returns explicit handoff guidance to the authenticated onboarding surfaces instead.

Setup session states

StatusDescription
NotStartedSetup not begun
InProgressSetup in progress
CompletedAll steps completed
CompletedPartialRequired steps completed, optional skipped
FailedRequired step failed
AbandonedSetup abandoned by user

Setup step states

StatusDescription
PendingNot yet started
PassedCompleted successfully
FailedValidation failed
SkippedExplicitly skipped (optional steps only)
CurrentReserved contract value for active-step projections
BlockedReserved contract value for dependency failures

Anonymous posture

Security and scopes

Offline posture