File tree 2 files changed +21
-2
lines changed
sled-agent/config-reconciler/src
2 files changed +21
-2
lines changed Original file line number Diff line number Diff line change @@ -141,6 +141,21 @@ impl LedgerTaskHandle {
141
141
unimplemented ! ( )
142
142
}
143
143
144
+ /// Confirm that a new [`ArtifactConfig`] is valid given the contents of the
145
+ /// currently-ledgered [`OmicronSledConfig`].
146
+ ///
147
+ /// In particular, this confirms that a new artifact config does not
148
+ /// _remove_ any artifacts needed by zones described by the current sled
149
+ /// config.
150
+ ///
151
+ /// The artifact store in sled agent and this task need to coordinate with
152
+ /// each other whenever changes are made to either kind of config. This
153
+ /// method provides a path for the artifact store to validate its incoming
154
+ /// artifact configs against this task, and this task uses the
155
+ /// implementation of [`SledAgentArtifactStore`] to validate its incoming
156
+ /// sled configs against the artifact store. Validation is always performed
157
+ /// by this task, which enforces serialization of the checks in the event of
158
+ /// requests arriving concurrently to change both configs.
144
159
pub async fn validate_artifact_config (
145
160
& self ,
146
161
_new_config : ArtifactConfig ,
Original file line number Diff line number Diff line change @@ -20,8 +20,12 @@ pub trait SledAgentFacilities: Send + 'static {
20
20
type MetricsUntrackZoneLinksError ;
21
21
type ZoneBundleCreateError ;
22
22
23
- /// Called once time is synchronized.
24
- // TODO-cleanup should we do this work ourselves instead?
23
+ /// Called by the reconciler task to inform sled-agent that time is
24
+ /// sychronized. May be called multiple times.
25
+ // TODO-cleanup should we do this work ourselves instead? This is
26
+ // currently implemented by `ServiceManager` and does a couple one-time
27
+ // setup things (like rewrite the OS boot time). We could probably absorb
28
+ // that work and remove this callback.
25
29
async fn on_time_sync ( & self ) ;
26
30
27
31
/// Method to start a zone.
You can’t perform that action at this time.
0 commit comments