diff options
| author | Ophestra <cat@gensokyo.uk> | 2026-06-20 01:03:28 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2026-06-20 01:03:28 +0900 |
| commit | a4fab678114b61c1c3473661577797ecf029514d (patch) | |
| tree | f86f898d05cb3d5861f9c13a0ebe81a2c8a41bd1 /internal/pkg/archive.go | |
| parent | ed5cdd38a40e0e121b8bc1c432bbb57ca584f798 (diff) | |
internal/pkg: optionally exempt implementations from cures counter
This avoids holding up many slots with a long pipeline.
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/pkg/archive.go')
| -rw-r--r-- | internal/pkg/archive.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/internal/pkg/archive.go b/internal/pkg/archive.go index 9f1b42d9..a58221e2 100644 --- a/internal/pkg/archive.go +++ b/internal/pkg/archive.go @@ -278,6 +278,8 @@ type archiveArtifact struct { f Artifact } +var _ CuresExempt = archiveArtifact{} + // NewArchive returns a new [Artifact] backed by the supplied [Artifact]. The // source [Artifact] must be a [FileArtifact] and produce a stream compatible // with [Reader]. @@ -403,3 +405,7 @@ func (a archiveArtifact) Cure(t *TContext) (err error) { } return } + +// CuresExempt exempts the cheap [KindArchive] implementation often found at +// the end of a [FileArtifact] pipeline. +func (archiveArtifact) CuresExempt() {} |
