MCPcopy Create free account
hub / github.com/baidu/EasyFaaS / recycleLoopDevice

Function recycleLoopDevice

pkg/funclet/storage/loop/loop.go:79–94  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

77}
78
79func recycleLoopDevice() {
80 loopDeviceMap, err := loop.GetLoopDeviceMap()
81 if err != nil {
82 return
83 }
84 for filePath, devices := range loopDeviceMap {
85 for _, device := range devices {
86 if strings.Contains(filePath, "faas-tmp") || device.IsDeleted {
87 if err := device.Detach(); err != nil {
88 continue
89 }
90 }
91 }
92 }
93 return
94}

Callers 1

RecycleMethod · 0.85

Calls 2

GetLoopDeviceMapFunction · 0.92
DetachMethod · 0.45

Tested by

no test coverage detected