master
go 40 lines 971 Bytes
Raw
1 //go:build !cgo
2
3 package pmi
4
5 import (
6 "context"
7 "errors"
8
9 "github.com/netdata/netdata/go/plugins/plugin/framework/collectorapi"
10 )
11
12 var configSchema string
13
14 type Collector struct{ collectorapi.Base }
15
16 func New() *Collector { return &Collector{} }
17
18 func (c *Collector) Configuration() any { return nil }
19
20 func (c *Collector) Init(context.Context) error {
21 return errors.New("websphere_pmi collector requires CGO support")
22 }
23
24 func (c *Collector) Check(context.Context) error {
25 return errors.New("websphere_pmi collector requires CGO support")
26 }
27
28 func (c *Collector) Charts() *collectorapi.Charts { return nil }
29
30 func (c *Collector) Collect(context.Context) map[string]int64 { return nil }
31
32 func (c *Collector) Cleanup(context.Context) {}
33
34 func init() {
35 collectorapi.Register("websphere_pmi", collectorapi.Creator{
36 JobConfigSchema: configSchema,
37 Create: func() collectorapi.CollectorV1 { return New() },
38 Config: func() any { return nil },
39 })
40 }