pub struct SafetyConfig {
pub enabled: bool,
pub block_on_danger: bool,
pub large_table_threshold: i64,
pub huge_table_threshold: i64,
pub refresh_stats_mysql: bool,
}Expand description
Configuration for safety analysis.
Fields§
§enabled: boolWhether safety analysis is enabled.
block_on_danger: boolWhether to block migrations that receive a DANGER verdict.
large_table_threshold: i64Row count threshold for classifying a table as Large.
huge_table_threshold: i64Row count threshold for classifying a table as Huge.
refresh_stats_mysql: boolMySQL only: run ANALYZE TABLE <name> on each affected table before
reading information_schema.tables.table_rows for size classification.
Off by default because ANALYZE TABLE acquires a brief metadata lock
and rewrites stats. Enable when you need accurate size classification
at the cost of touching the table — typically during a CI safety check
rather than at production-migrate time.
Trait Implementations§
Source§impl Clone for SafetyConfig
impl Clone for SafetyConfig
Source§fn clone(&self) -> SafetyConfig
fn clone(&self) -> SafetyConfig
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 moreSource§impl Debug for SafetyConfig
impl Debug for SafetyConfig
Auto Trait Implementations§
impl Freeze for SafetyConfig
impl RefUnwindSafe for SafetyConfig
impl Send for SafetyConfig
impl Sync for SafetyConfig
impl Unpin for SafetyConfig
impl UnsafeUnpin for SafetyConfig
impl UnwindSafe for SafetyConfig
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