argo-workflows icon indicating copy to clipboard operation
argo-workflows copied to clipboard

fix: allow artifact delete to delete directory. Fixes #12857

Open tczhao opened this issue 9 months ago • 0 comments

Fixes #12857

Motivation

We see error The specified key does not exist when gc artifact are not compressed and is directory

Modifications

Determine if artifact is dir and delete accordingly (used in artifact gc)

Verification

Test log

time="2024-05-25T03:16:16.108Z" level=info msg="S3 Delete artifactttt: key: fanout/collected-other-datasets/yo-test-zl4wk/"
time="2024-05-25T03:16:16.108Z" level=info msg="Creating minio client using static credentials" endpoint="minio:9000"
time="2024-05-25T03:16:16.112Z" level=info msg="Listing directory from s3" bucket=my-bucket endpoint="minio:9000" key=fanout/collected-other-datasets/yo-test-zl4wk/
time="2024-05-25T03:16:16.113Z" level=info msg="Deleting object from s3" bucket=my-bucket endpoint="minio:9000" key=fanout/collected-other-datasets/yo-test-zl4wk/hello-world.txt
time="2024-05-25T03:16:16.115Z" level=info msg="Deleting object from s3" bucket=my-bucket endpoint="minio:9000" key=fanout/collected-other-datasets/yo-test-zl4wk/hello-world2.txt

tczhao avatar May 25 '24 03:05 tczhao