You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
oras cp is by-design to stop on the first-met error. if the copy destination is an OCI-1.0-compliant registry with deletion disabled, then oras cp operation might be done half-way without copying all the nodes.
Consider copying the below artifacts via index A to such a registry(OCI 1.0+delete disabled) with concurrency set to 1.
The copy process will cover all referrers of E, since the concurrency is set to 1, those three referrers, B, C and D will be copied one by one. Let's assume the sequence is B -> C -> D:
When copying B, the referrer index is created with one descriptor pointing to B
When copying C, the referrer index created in step 1) is fetched and append another descriptor of B. The referrer index created in step 1) is dangling and need to be cleaned up
clean up will fail and copy terminated
In this case, D is not covered and the copy process stops.
Why is this needed for ORAS?
Copying progress should not be terminated when such failure encountered, it is not terminal and user can clean up the dangling referrer index after the cp process.
Are you willing to submit PRs to contribute to this feature?
Yes, I am willing to implement it.
The text was updated successfully, but these errors were encountered:
qweeah
changed the title
oras cp should not be terminated by failure when deleting dangling referrers index
make oras cp skip dangling referrers index deletion error
May 22, 2023
What is the version of your ORAS CLI
1.0.0
What would you like to be added?
oras cp
is by-design to stop on the first-met error. if the copy destination is an OCI-1.0-compliant registry with deletion disabled, thenoras cp
operation might be done half-way without copying all the nodes.Consider copying the below artifacts via index
A
to such a registry(OCI 1.0+delete disabled) with concurrency set to 1.The copy process will cover all referrers of
E
, since the concurrency is set to 1, those three referrers,B
,C
andD
will be copied one by one. Let's assume the sequence isB
->C
->D
:B
, the referrer index is created with one descriptor pointing toB
C
, the referrer index created in step 1) is fetched and append another descriptor ofB
. The referrer index created in step 1) is dangling and need to be cleaned upIn this case,
D
is not covered and the copy process stops.Why is this needed for ORAS?
Copying progress should not be terminated when such failure encountered, it is not terminal and user can clean up the dangling referrer index after the cp process.
Are you willing to submit PRs to contribute to this feature?
The text was updated successfully, but these errors were encountered: