Skip to main content

nxd_core/ports/
observe.rs

1//! Observe-side ports used by application services.
2//!
3//! Observation is owned by providers behind the asynchronous core port.
4//! Only provider-independent deployment-target observation remains in core.
5
6use crate::contract::CanonicalConfig;
7use crate::host_lifecycle::ObservedDeploymentTarget;
8use std::collections::BTreeSet;
9
10/// Side-effect-free observation of deployment targets (no SSH trust mutation).
11pub trait DeploymentTargetObservePort {
12	fn observe(
13		&self,
14		config: &CanonicalConfig,
15		resource_ids: &BTreeSet<String>,
16	) -> Result<Vec<ObservedDeploymentTarget>, String>;
17}