MCPcopy
hub / github.com/TecharoHQ/anubis / Close

Method Close

decaymap/decaymap.go:140–143  ·  view source on GitHub ↗

Close stops the background cleanup worker. It's optional to call; maps live for the process lifetime in many cases. Call in tests or when you know you no longer need the map to avoid goroutine leaks.

()

Source from the content-addressed store, hash-verified

138// for the process lifetime in many cases. Call in tests or when you know you no
139// longer need the map to avoid goroutine leaks.
140func (m *Impl[K, V]) Close() {
141 close(m.stopCh)
142 m.wg.Wait()
143}
144
145// cleanupWorker batches decay deletions to minimize lock contention.
146func (m *Impl[K, V]) cleanupWorker() {

Callers 15

FetchBlocklistFunction · 0.45
mainFunction · 0.45
mainFunction · 0.45
GzipMiddlewareFunction · 0.45
TestFetchHTMLDocumentFunction · 0.45
TestIntegrationGetOGTagsFunction · 0.45

Calls

no outgoing calls