mirror of
https://github.com/rustfs/rustfs.git
synced 2026-08-25 13:36:50 +00:00
fix(ecstore): satisfy delete fence lint checks
This commit is contained in:
@@ -1545,13 +1545,12 @@ async fn migrate_object_inner(
|
|||||||
if let Err(err) = store
|
if let Err(err) = store
|
||||||
.clone()
|
.clone()
|
||||||
.complete_multipart_upload_for_data_movement(
|
.complete_multipart_upload_for_data_movement(
|
||||||
target_pool_idx,
|
(target_pool_idx, mutation_fence),
|
||||||
&bucket,
|
&bucket,
|
||||||
&object_info.name,
|
&object_info.name,
|
||||||
&res.upload_id,
|
&res.upload_id,
|
||||||
parts,
|
parts,
|
||||||
&complete_multipart_opts,
|
&complete_multipart_opts,
|
||||||
mutation_fence,
|
|
||||||
)
|
)
|
||||||
.await
|
.await
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -3538,7 +3538,7 @@ mod tests {
|
|||||||
"the injected error pool must be the decommission source"
|
"the injected error pool must be the decommission source"
|
||||||
);
|
);
|
||||||
|
|
||||||
let expected_errors = vec![
|
let expected_errors = [
|
||||||
StorageError::ErasureWriteQuorum,
|
StorageError::ErasureWriteQuorum,
|
||||||
StorageError::NamespaceLockQuorumUnavailable {
|
StorageError::NamespaceLockQuorumUnavailable {
|
||||||
mode: "delete_objects_commit",
|
mode: "delete_objects_commit",
|
||||||
|
|||||||
@@ -712,14 +712,14 @@ impl ECStore {
|
|||||||
|
|
||||||
pub(crate) async fn complete_multipart_upload_for_data_movement(
|
pub(crate) async fn complete_multipart_upload_for_data_movement(
|
||||||
self: Arc<Self>,
|
self: Arc<Self>,
|
||||||
target_pool_idx: usize,
|
target: (usize, Option<&ObjectLockDiagGuard>),
|
||||||
bucket: &str,
|
bucket: &str,
|
||||||
object: &str,
|
object: &str,
|
||||||
upload_id: &str,
|
upload_id: &str,
|
||||||
uploaded_parts: Vec<CompletePart>,
|
uploaded_parts: Vec<CompletePart>,
|
||||||
opts: &ObjectOptions,
|
opts: &ObjectOptions,
|
||||||
mutation_fence: Option<&ObjectLockDiagGuard>,
|
|
||||||
) -> Result<ObjectInfo> {
|
) -> Result<ObjectInfo> {
|
||||||
|
let (target_pool_idx, mutation_fence) = target;
|
||||||
check_complete_multipart_args(bucket, object, upload_id)?;
|
check_complete_multipart_args(bucket, object, upload_id)?;
|
||||||
if !opts.data_movement {
|
if !opts.data_movement {
|
||||||
return Err(Error::other("targeted multipart completion requires data_movement options"));
|
return Err(Error::other("targeted multipart completion requires data_movement options"));
|
||||||
|
|||||||
Reference in New Issue
Block a user