MCPcopy Create free account
hub / github.com/actiontech/dtle / FreeMemoryWorker

Function FreeMemoryWorker

g/g.go:90–101  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

88)
89
90func FreeMemoryWorker() {
91 if !atomic.CompareAndSwapInt32(&freeMemoryWorkerCount, 0, 1) {
92 return
93 }
94 for {
95 select {
96 case <-freeMemoryCh:
97 debug.FreeOSMemory()
98 time.Sleep(10 * time.Second)
99 }
100 }
101}
102
103func TriggerFreeMemory() {
104 select {

Callers 1

NewDriverFunction · 0.92

Calls

no outgoing calls

Tested by

no test coverage detected