pub struct NamedDatabaseConfig {
pub name: String,
pub database: DatabaseConfig,
pub migrations: MigrationSettings,
pub hooks: HooksConfig,
pub placeholders: HashMap<String, String>,
pub depends_on: Vec<String>,
}Expand description
Configuration for a single named database within a multi-db setup.
Fields§
§name: StringUnique logical name identifying this database.
database: DatabaseConfigDatabase connection configuration.
migrations: MigrationSettingsMigration settings for this database.
hooks: HooksConfigHook configuration for this database.
placeholders: HashMap<String, String>Placeholder key-value pairs for SQL template substitution.
depends_on: Vec<String>Names of other databases that must be migrated before this one.
Implementations§
Source§impl NamedDatabaseConfig
impl NamedDatabaseConfig
Sourcepub fn to_waypoint_config(&self) -> WaypointConfig
pub fn to_waypoint_config(&self) -> WaypointConfig
Convert to a standalone WaypointConfig for running commands.
Trait Implementations§
Source§impl Clone for NamedDatabaseConfig
impl Clone for NamedDatabaseConfig
Source§fn clone(&self) -> NamedDatabaseConfig
fn clone(&self) -> NamedDatabaseConfig
Returns a duplicate of the value. Read more
1.0.0 · 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 NamedDatabaseConfig
impl RefUnwindSafe for NamedDatabaseConfig
impl Send for NamedDatabaseConfig
impl Sync for NamedDatabaseConfig
impl Unpin for NamedDatabaseConfig
impl UnsafeUnpin for NamedDatabaseConfig
impl UnwindSafe for NamedDatabaseConfig
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