pub struct MigrationExecutor { /* private fields */ }Expand description
Executes migration plans against a source and target Docker daemon.
Implementations§
Source§impl MigrationExecutor
impl MigrationExecutor
Sourcepub fn new(target: DockerCliRunner) -> Self
pub fn new(target: DockerCliRunner) -> Self
Creates an executor for the provided ArcBox target socket.
Sourcepub async fn execute<F>(
&self,
source: SourceConfig,
plan: &MigrationPlan,
options: MigrationExecutorOptions,
progress: F,
) -> Result<MigrationOutcome>where
F: FnMut(MigrationProgress),
pub async fn execute<F>(
&self,
source: SourceConfig,
plan: &MigrationPlan,
options: MigrationExecutorOptions,
progress: F,
) -> Result<MigrationOutcome>where
F: FnMut(MigrationProgress),
Executes a migration plan, returning any non-fatal problems.
A returned outcome means the migration ran to completion; its warnings
describe what the caller must surface alongside that result. Completion
is not “everything arrived”: failures scoped to one container — it could
not be created, could not join every network, or did not start — are
reported per container and the run continues, because the alternative
abandons an otherwise migrated environment partway through. Only a
failure that invalidates the whole plan (a rejected precondition, or an
image, volume or network that every later step depends on) returns Err.