Closed synologic closed 5 years ago
@synologic It looks like you haven't done go get
before go build
to fetch the dependencies.
Correct, go get github.com/msiedlarek/nifi_exporter
should be enough to get the source, all dependencies, compile and install.
Hi,
i'm having an issue when trying to build your project. I'm not a GO dev, however when i try go build i get: ./main.go:111: cannot use collectors.NewDiagnosticsCollector(api, node.Labels) (type collectors.DiagnosticsCollector) as type "github.com/prometheus/client_golang/prometheus".Collector in argument to "github.com/prometheus/client_golang/prometheus".DefaultRegisterer.Register: collectors.DiagnosticsCollector does not implement "github.com/prometheus/client_golang/prometheus".Collector (wrong type for Collect method) have Collect(chan<- "github.com/msiedlarek/nifi_exporter/vendor/github.com/prometheus/client_golang/prometheus".Metric) want Collect(chan<- "github.com/prometheus/client_golang/prometheus".Metric) ./main.go:114: cannot use collectors.NewCountersCollector(api, node.Labels) (type collectors.CountersCollector) as type "github.com/prometheus/client_golang/prometheus".Collector in argument to "github.com/prometheus/client_golang/prometheus".DefaultRegisterer.Register: collectors.CountersCollector does not implement "github.com/prometheus/client_golang/prometheus".Collector (wrong type for Collect method) have Collect(chan<- "github.com/msiedlarek/nifi_exporter/vendor/github.com/prometheus/client_golang/prometheus".Metric) want Collect(chan<- "github.com/prometheus/client_golang/prometheus".Metric) ./main.go:117: cannot use collectors.NewProcessGroupsCollector(api, node.Labels) (type collectors.ProcessGroupsCollector) as type "github.com/prometheus/client_golang/prometheus".Collector in argument to "github.com/prometheus/client_golang/prometheus".DefaultRegisterer.Register: collectors.ProcessGroupsCollector does not implement "github.com/prometheus/client_golang/prometheus".Collector (wrong type for Collect method) have Collect(chan<- "github.com/msiedlarek/nifi_exporter/vendor/github.com/prometheus/client_golang/prometheus".Metric) want Collect(chan<- "github.com/prometheus/client_golang/prometheus".Metric)
Please advise