fix(transfer): keep task active after table errors
This commit is contained in:
1 parent
e25be6335d
commit
15d392bc44
9 files changed
+119
-11
No files matched your search
@@ -79,6 +79,7 @@ pub async fn start_transfer(
|
||||
total_rows: None,
|
||||
status: TransferStatus::Cancelled,
|
||||
error: None,
|
||||
terminal: true,
|
||||
},
|
||||
);
|
||||
dbx_core::transfer::clear_cancelled(&transfer_id).await;
|
||||
@@ -96,6 +97,7 @@ pub async fn start_transfer(
|
||||
total_rows: None,
|
||||
status: TransferStatus::Error,
|
||||
error: Some(e),
|
||||
terminal: true,
|
||||
},
|
||||
);
|
||||
dbx_core::transfer::clear_cancelled(&transfer_id).await;
|
||||
@@ -118,6 +120,7 @@ pub async fn start_transfer(
|
||||
total_rows: None,
|
||||
status: TransferStatus::Cancelled,
|
||||
error: None,
|
||||
terminal: true,
|
||||
},
|
||||
);
|
||||
dbx_core::transfer::clear_cancelled(&transfer_id).await;
|
||||
@@ -158,6 +161,7 @@ pub async fn start_transfer(
|
||||
total_rows: last_total_rows.or(Some(rows)),
|
||||
status: TransferStatus::TableDone,
|
||||
error: None,
|
||||
terminal: false,
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -174,6 +178,7 @@ pub async fn start_transfer(
|
||||
total_rows: None,
|
||||
status: TransferStatus::Cancelled,
|
||||
error: None,
|
||||
terminal: true,
|
||||
},
|
||||
);
|
||||
dbx_core::transfer::clear_cancelled(&transfer_id).await;
|
||||
@@ -191,6 +196,7 @@ pub async fn start_transfer(
|
||||
total_rows: last_total_rows,
|
||||
status: TransferStatus::Error,
|
||||
error: Some(e),
|
||||
terminal: false,
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -222,6 +228,7 @@ pub async fn start_transfer(
|
||||
total_rows: None,
|
||||
status: TransferStatus::Cancelled,
|
||||
error: None,
|
||||
terminal: true,
|
||||
},
|
||||
);
|
||||
dbx_core::transfer::clear_cancelled(&transfer_id).await;
|
||||
@@ -240,6 +247,7 @@ pub async fn start_transfer(
|
||||
total_rows: None,
|
||||
status: TransferStatus::Error,
|
||||
error: Some(e),
|
||||
terminal: false,
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -265,6 +273,7 @@ pub async fn start_transfer(
|
||||
failed_tables.iter().take(5).cloned().collect::<Vec<_>>().join(", ")
|
||||
))
|
||||
},
|
||||
terminal: true,
|
||||
},
|
||||
);
|
||||
dbx_core::transfer::clear_cancelled(&transfer_id).await;
|
||||
|
||||
Reference in new issue
Block a user