MCPcopy Index your code
hub / github.com/containerd/containerd / Info

Method Info

core/mount/manager/manager.go:806–824  ·  view source on GitHub ↗
(ctx context.Context, name string)

Source from the content-addressed store, hash-verified

804}
805
806func (mm *mountManager) Info(ctx context.Context, name string) (mount.ActivationInfo, error) {
807 namespace, err := namespaces.NamespaceRequired(ctx)
808 if err != nil {
809 return mount.ActivationInfo{}, err
810 }
811 var info mount.ActivationInfo
812 if err := mm.db.View(func(tx *bolt.Tx) error {
813 bkt := getBucket(tx, []byte("v1"), []byte(namespace), bucketKeyMounts, []byte(name))
814 if bkt == nil {
815 return fmt.Errorf("mount %q %w", name, errdefs.ErrNotFound)
816 }
817 var err error
818 info, err = readActivationInfo(name, bkt)
819 return err
820 }); err != nil {
821 return mount.ActivationInfo{}, err
822 }
823 return info, nil
824}
825
826func (mm *mountManager) Update(context.Context, mount.ActivationInfo, ...string) (mount.ActivationInfo, error) {
827 return mount.ActivationInfo{}, errdefs.ErrNotImplemented

Callers

nothing calls this directly

Calls 4

NamespaceRequiredFunction · 0.92
readActivationInfoFunction · 0.85
getBucketFunction · 0.70
ViewMethod · 0.65

Tested by

no test coverage detected