Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

refactor(storage): update storage grant schema usage

Steven Enamakelc6ebe7920950
diff --git a/crates/openhuman-core/src/modules/storage_grant_schemas.rs b/crates/openhuman-core/src/modules/storage_grant_schemas.rs
index 49d088dc09..8ab64d42c3 100644
--- a/crates/openhuman-core/src/modules/storage_grant_schemas.rs
+++ b/crates/openhuman-core/src/modules/storage_grant_schemas.rs
@@ -22,7 +22,7 @@ use std::sync::Arc;
use super::storage_grants::StorageGrant;
use super::storage_queue_manifest::QueueManifest;
-use crate::storage::schema::module_items;
+use crate::storage::schema::module_collections;
/// One module's row: its registry id, the schema owner that declares its
/// storage, secret prefixes the schema cannot name, and the queue manifest the
@@ -130,11 +130,13 @@ pub(super) async fn migrate_imported(ctx: &crate::core::runtime::DispatchCtx, mo
pub(super) fn grant_for(module_id: &str) -> Option<StorageGrant> {
let row = ROWS.iter().find(|row| row.module == module_id)?;
let queues = row.queues.and_then(|source| source());
- let items = module_items(row.owner);
+ let collections = module_collections(row.owner);
let mut secret_prefixes: Vec<String> = row.secrets.iter().map(|s| (*s).to_owned()).collect();
- secret_prefixes.extend(items.secrets);
+ // Collection declarations are now the owner contracts' only published
+ // storage inventory. Stream/blob/secret grants remain explicit below
+ // until their bus contracts expose equivalent pure descriptors.
Some(StorageGrant {
- collections: items.collections,
+ collections,
// v2 owner bus crates expose their collection declarations, but not
// every non-document name. Keep those capabilities explicit at the
// host boundary until the owner contracts publish them. Connectors