Record the `TenantId → DatabaseId` mapping for a tenant seen in a request. Called by dispatch handlers when `task.request.database_id` is available so the maintenance budget tracker can look up per-database caps when iterating collections that are keyed only by `TenantId`.
(
&mut self,
tenant: crate::types::TenantId,
db: nodedb_types::DatabaseId,
)
| 45 | /// so the maintenance budget tracker can look up per-database caps when |
| 46 | /// iterating collections that are keyed only by `TenantId`. |
| 47 | pub(in crate::data::executor) fn record_tenant_database( |
| 48 | &mut self, |
| 49 | tenant: crate::types::TenantId, |
| 50 | db: nodedb_types::DatabaseId, |
| 51 | ) { |
| 52 | self.tenant_database_map.entry(tenant).or_insert(db); |
| 53 | } |
| 54 | |
| 55 | /// Register a `TenantId → DatabaseId` mapping. |
| 56 | /// |