pub struct AppContextBuilder { /* private fields */ }Expand description
Assembles an AppContext, owning the bootstrap order described on the
module.
All fields default to a no-op build: extensions are discovered via
inventory, schema installation is off, and the marketplace filter falls
back to the inventory-registered implementation (or an allow-all filter).
Override these with the with_* methods before calling
build.
Implementations§
Source§impl AppContextBuilder
impl AppContextBuilder
pub fn new() -> Self
Sourcepub fn with_extensions(self, registry: ExtensionRegistry) -> Self
pub fn with_extensions(self, registry: ExtensionRegistry) -> Self
Supplies an explicit extension registry. When unset, build()
discovers extensions via inventory (ExtensionRegistry::discover).
pub const fn with_startup_warnings(self, show: bool) -> Self
Sourcepub fn with_marketplace_filter(self, filter: Arc<dyn MarketplaceFilter>) -> Self
pub fn with_marketplace_filter(self, filter: Arc<dyn MarketplaceFilter>) -> Self
Supplies an explicit marketplace filter. When unset, build() selects
the highest-priority inventory-registered filter, falling back to an
allow-all filter when none succeeds.
Sourcepub const fn with_migrations(self, install: bool) -> Self
pub const fn with_migrations(self, install: bool) -> Self
Install / migrate extension schemas as part of build(). Off by
default so admin tools (db doctor, repair scripts) can open a
connection without mutating the schema. serve turns this on.
pub const fn with_migration_config(self, config: MigrationConfig) -> Self
pub async fn build(self) -> RuntimeResult<AppContext>
Trait Implementations§
Source§impl Debug for AppContextBuilder
impl Debug for AppContextBuilder
Source§impl Default for AppContextBuilder
impl Default for AppContextBuilder
Source§fn default() -> AppContextBuilder
fn default() -> AppContextBuilder
Auto Trait Implementations§
impl Freeze for AppContextBuilder
impl !RefUnwindSafe for AppContextBuilder
impl Send for AppContextBuilder
impl Sync for AppContextBuilder
impl Unpin for AppContextBuilder
impl UnsafeUnpin for AppContextBuilder
impl !UnwindSafe for AppContextBuilder
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more