MCPcopy
hub / github.com/containerd/containerd / ListStatuses

Method ListStatuses

core/content/proxy/content_store.go:165–186  ·  view source on GitHub ↗
(ctx context.Context, filters ...string)

Source from the content-addressed store, hash-verified

163}
164
165func (pcs *proxyContentStore) ListStatuses(ctx context.Context, filters ...string) ([]content.Status, error) {
166 resp, err := pcs.client.ListStatuses(ctx, &contentapi.ListStatusesRequest{
167 Filters: filters,
168 })
169 if err != nil {
170 return nil, errgrpc.ToNative(err)
171 }
172
173 var statuses []content.Status
174 for _, status := range resp.Statuses {
175 statuses = append(statuses, content.Status{
176 Ref: status.Ref,
177 StartedAt: protobuf.FromTimestamp(status.StartedAt),
178 UpdatedAt: protobuf.FromTimestamp(status.UpdatedAt),
179 Offset: status.Offset,
180 Total: status.Total,
181 Expected: digest.Digest(status.Expected),
182 })
183 }
184
185 return statuses, nil
186}
187
188// Writer ignores MediaType.
189func (pcs *proxyContentStore) Writer(ctx context.Context, opts ...content.WriterOpt) (content.Writer, error) {

Callers

nothing calls this directly

Calls 3

FromTimestampFunction · 0.92
ListStatusesMethod · 0.65
DigestMethod · 0.65

Tested by

no test coverage detected