MCPcopy Create free account
hub / github.com/GoEdgeLab/EdgeNode / NewOpenFilePool

Function NewOpenFilePool

internal/caches/open_file_pool.go:19–27  ·  view source on GitHub ↗
(filename string)

Source from the content-addressed store, hash-verified

17}
18
19func NewOpenFilePool(filename string) *OpenFilePool {
20 var pool = &OpenFilePool{
21 filename: filename,
22 c: make(chan *OpenFile, 1024),
23 version: fasttime.Now().UnixMilli(),
24 }
25 pool.linkItem = linkedlist.NewItem[*OpenFilePool](pool)
26 return pool
27}
28
29func (this *OpenFilePool) Filename() string {
30 return this.filename

Callers 4

TestOpenFilePool_GetFunction · 0.92
TestOpenFilePool_CloseFunction · 0.92
PutMethod · 0.85

Calls 2

NowFunction · 0.92
UnixMilliMethod · 0.80

Tested by 3

TestOpenFilePool_GetFunction · 0.74
TestOpenFilePool_CloseFunction · 0.74