pub struct ServiceContext {
pub factory: Factory,
pub catalogs: Arc<Manager>,
pub default_sub_account_id: Option<String>,
pub default_account_id: Option<String>,
pub realtime: Client,
pub catalog_ready: Arc<OnceCell<Result<()>>>,
pub hydrate_catalogs_enabled: bool,
}Expand description
Shared dependencies for service constructors.
Fields§
§factory: Factory§catalogs: Arc<Manager>§default_sub_account_id: Option<String>§default_account_id: Option<String>§realtime: Client§catalog_ready: Arc<OnceCell<Result<()>>>§hydrate_catalogs_enabled: boolImplementations§
Source§impl ServiceContext
impl ServiceContext
Sourcepub async fn wait_for_catalogs(&self) -> Result<()>
pub async fn wait_for_catalogs(&self) -> Result<()>
Wait for construction-time catalog hydration when enabled.
Propagates hydration failure so order paths do not proceed with empty catalogs.
Trait Implementations§
Source§impl Clone for ServiceContext
impl Clone for ServiceContext
Source§fn clone(&self) -> ServiceContext
fn clone(&self) -> ServiceContext
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl !Freeze for ServiceContext
impl !RefUnwindSafe for ServiceContext
impl !UnwindSafe for ServiceContext
impl Send for ServiceContext
impl Sync for ServiceContext
impl Unpin for ServiceContext
impl UnsafeUnpin for ServiceContext
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more