MCPcopy
hub / github.com/netdata/netdata / Add

Method Add

src/go/plugin/framework/confgroup/cache.go:17–27  ·  view source on GitHub ↗
(group *Group)

Source from the content-addressed store, hash-verified

15}
16
17func (c *Cache) Add(group *Group) (added, removed []Config) {
18 if group == nil {
19 return nil, nil
20 }
21
22 if len(group.Configs) == 0 {
23 return c.addEmpty(group)
24 }
25
26 return c.addNotEmpty(group)
27}
28
29func (c *Cache) addEmpty(group *Group) (added, removed []Config) {
30 set, ok := c.sources[group.Source]

Callers 1

TestConfigCache_AddFunction · 0.95

Calls 2

addEmptyMethod · 0.95
addNotEmptyMethod · 0.95

Tested by 1

TestConfigCache_AddFunction · 0.76