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

Function NewKVIPList

internal/iplibrary/ip_list_kv.go:32–39  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

30}
31
32func NewKVIPList() (*KVIPList, error) {
33 var db = &KVIPList{
34 cleanTicker: time.NewTicker(24 * time.Hour),
35 encoder: &IPItemEncoder[*pb.IPItem]{},
36 }
37 err := db.init()
38 return db, err
39}
40
41func (this *KVIPList) init() error {
42 store, storeErr := kvstore.DefaultStore()

Callers 9

TestKVIPList_AddItemFunction · 0.92
TestKVIPList_ReadItemsFunction · 0.92
TestKVIPList_CountItemsFunction · 0.92
TestKVIPList_InspectFunction · 0.92
InitMethod · 0.85

Calls 1

initMethod · 0.45

Tested by 8

TestKVIPList_AddItemFunction · 0.74
TestKVIPList_ReadItemsFunction · 0.74
TestKVIPList_CountItemsFunction · 0.74
TestKVIPList_InspectFunction · 0.74