Skip to content
This repository was archived by the owner on Oct 9, 2023. It is now read-only.

Commit bda210e

Browse files
author
Nick Müller
committed
Added method to release catalog reservation by artifact tag
Added method to delete catalog artifact by ID Signed-off-by: Nick Müller <nmueller@blackshark.ai>
1 parent 4593b01 commit bda210e

File tree

2 files changed

+70
-0
lines changed

2 files changed

+70
-0
lines changed

go/tasks/pluginmachinery/catalog/client.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,11 +142,17 @@ type Client interface {
142142
Update(ctx context.Context, key Key, reader io.OutputReader, metadata Metadata) (Status, error)
143143
// ReleaseReservation releases an acquired reservation for the given key and owner ID.
144144
ReleaseReservation(ctx context.Context, key Key, ownerID string) error
145+
// ReleaseReservationByArtifactTag releases an acquired reservation for the given dataset ID, artifact tag and
146+
// owner ID.
147+
ReleaseReservationByArtifactTag(ctx context.Context, datasetID *datacatalog.DatasetID, artifactTag string, ownerID string) error
145148
// Delete removes the artifact associated with the given key and deletes its underlying data from blob storage.
146149
Delete(ctx context.Context, key Key) error
147150
// DeleteByArtifactTag removes the artifact associated with the given dataset ID and artifact tag and deletes its
148151
// underlying data from blob storage.
149152
DeleteByArtifactTag(ctx context.Context, datasetID *datacatalog.DatasetID, artifactTag string) error
153+
// DeleteByArtifactID removes the artifact associated with the given dataset and artifact ID and deletes its
154+
// underlying data from blob storage.
155+
DeleteByArtifactID(ctx context.Context, datasetID *datacatalog.DatasetID, artifactID string) error
150156
}
151157

152158
func IsNotFound(err error) bool {

go/tasks/pluginmachinery/catalog/mocks/client.go

Lines changed: 64 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)