pub fn load_cache(
path: &PathBuf,
current_signature: &[String],
) -> Option<Vec<ServiceImpact>>Expand description
What: Load cached service impact data when the stored signature matches the current list.
Inputs:
path: Filesystem location of the serializedServiceCacheJSON.current_signature: Signature derived from the current install list for validation.
Output:
Some(Vec<ServiceImpact>)when the cache exists, deserializes, and signatures agree;Noneotherwise.
Details:
- Reads the JSON, deserializes it, sorts both signatures, and compares them before returning the cached service impact data.