MCPcopy Create free account
hub / github.com/PerpetualSoftware/pad / uploadInFlight

Method uploadInFlight

internal/server/server.go:1358–1360  ·  view source on GitHub ↗

uploadInFlight reports whether any upload is currently materializing a blob with the given hash. The orphan GC consults this before deleting a blob — if an upload just finished Put but hasn't inserted the row yet, GC must NOT reclaim the blob.

(hash string)

Source from the content-addressed store, hash-verified

1356// deleting a blob — if an upload just finished Put but hasn't
1357// inserted the row yet, GC must NOT reclaim the blob.
1358func (s *Server) uploadInFlight(hash string) bool {
1359 return s.inFlight.Active(hash)
1360}
1361
1362// UploadInFlight is the process's upload hash guard, shared with the app
1363// store so an app upload fences against the same orphan-GC sweep the human

Calls 1

ActiveMethod · 0.80