Delete unconsumed release and trust readers
This commit is contained in:
parent
47e0c413f1
commit
f6a2ad7f84
3 changed files with 2 additions and 25 deletions
|
|
@ -107,22 +107,6 @@ pub struct IdunnProviderHealthAdmission {
|
|||
pub trust_anchor_bound_at_unix_millis: u64,
|
||||
}
|
||||
|
||||
pub fn read_idunn_provider_health_trust_anchor(
|
||||
path: &Path,
|
||||
) -> Result<GameCultServiceTrustAnchorRecord> {
|
||||
let rows = SingleFileMessagePackBackingStore::new(path).pull_all_read_only_snapshot()?;
|
||||
if rows.len() != 1 {
|
||||
bail!("Idunn provider-health trust anchor store must contain exactly one row");
|
||||
}
|
||||
let row = &rows[0];
|
||||
if row.r#type != GameCultServiceTrustAnchorRecord::TYPE {
|
||||
bail!("Idunn provider-health trust anchor store contains foreign authority");
|
||||
}
|
||||
let anchor: GameCultServiceTrustAnchorRecord = rmp_serde::from_slice(&row.payload)?;
|
||||
anchor.validate()?;
|
||||
Ok(anchor)
|
||||
}
|
||||
|
||||
pub fn provider_health_record_key(daemon_id: &str, health_contract: &str) -> String {
|
||||
format!(
|
||||
"provider-health:{:x}",
|
||||
|
|
|
|||
|
|
@ -122,7 +122,7 @@ pub use idunn_provider_health::{
|
|||
EPIPHANY_IDUNN_PROVIDER_HEALTH_ADMISSION_SCHEMA, EPIPHANY_IDUNN_PROVIDER_HEALTH_ADMISSION_TYPE,
|
||||
IdunnProviderHealthAdmission, ProviderReleaseBinding, RequiredProviderHealth,
|
||||
admit_required_idunn_provider_health, provider_health_record_key,
|
||||
read_idunn_provider_health_trust_anchor, required_idunn_provider_health_query,
|
||||
required_idunn_provider_health_query,
|
||||
verify_idunn_provider_health_candidate,
|
||||
};
|
||||
pub use idunn_runtime_health::{
|
||||
|
|
@ -162,7 +162,7 @@ pub use packaged_release::{
|
|||
EpiphanyPackagedReleaseEntry, EpiphanyPackagedReleaseHead, PackageReleaseRequest,
|
||||
authenticate_epiphany_packaged_release, epiphany_packaged_release_binary_path,
|
||||
epiphany_packaged_release_witness_sha256, inspect_epiphany_packaged_release_witness,
|
||||
load_epiphany_packaged_release, load_epiphany_packaged_release_head, package_epiphany_release,
|
||||
load_epiphany_packaged_release, package_epiphany_release,
|
||||
publish_epiphany_packaged_release, read_epiphany_packaged_release_witness,
|
||||
required_packaged_release_binaries, validate_epiphany_packaged_release,
|
||||
verify_epiphany_packaged_release_files, write_epiphany_packaged_release_witness,
|
||||
|
|
|
|||
|
|
@ -61,13 +61,6 @@ pub fn load_epiphany_packaged_release(
|
|||
.get(&format!("{RELEASE_KEY_PREFIX}{release_id}"))
|
||||
}
|
||||
|
||||
pub fn load_epiphany_packaged_release_head(
|
||||
store: &Path,
|
||||
runtime_id: &str,
|
||||
) -> Result<Option<EpiphanyPackagedReleaseHead>> {
|
||||
open_epiphany_cultmesh_node(store, runtime_id.to_string())?.get(RELEASE_HEAD_KEY)
|
||||
}
|
||||
|
||||
pub fn authenticate_epiphany_packaged_release(
|
||||
store: &Path,
|
||||
runtime_id: &str,
|
||||
|
|
|
|||
Reference in a new issue