File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -866,8 +866,23 @@ where
866866 } else {
867867 Either :: B ( NoStorage )
868868 } . into ( ) ;
869+
870+ let primary_config = PrimaryConfig {
871+ max_log_size : self . db_config . max_log_size ,
872+ max_log_duration : self . db_config . max_log_duration . map ( Duration :: from_secs_f32) ,
873+ bottomless_replication : self . db_config . bottomless_replication . clone ( ) ,
874+ scripted_backup,
875+ checkpoint_interval : self . db_config . checkpoint_interval ,
869876 } ;
870877
878+ // perform migration before creating the actual registry creation
879+ self . maybe_migrate_bottomless (
880+ meta_store,
881+ storage. clone ( ) ,
882+ & base_config,
883+ & primary_config,
884+ ) . await ?;
885+
871886 if self . rpc_server_config . is_some ( ) && matches ! ( * storage, Either :: B ( _) ) {
872887 anyhow:: bail!( "replication without bottomless not supported yet" ) ;
873888 }
@@ -930,13 +945,6 @@ where
930945 }
931946 // configure primary
932947 None => {
933- let primary_config = PrimaryConfig {
934- max_log_size: self . db_config. max_log_size,
935- max_log_duration: self . db_config. max_log_duration. map( Duration :: from_secs_f32) ,
936- bottomless_replication: self . db_config. bottomless_replication. clone( ) ,
937- scripted_backup,
938- checkpoint_interval: self . db_config. checkpoint_interval,
939- } ;
940948 let primary_configurator = LibsqlPrimaryConfigurator :: new (
941949 base_config. clone ( ) ,
942950 primary_config. clone ( ) ,
You can’t perform that action at this time.
0 commit comments