Remove config from collectors.

This commit is contained in:
Siavash Safi 2015-06-23 18:19:18 +04:30
commit f7563fe7a2
5 changed files with 8 additions and 21 deletions

View file

@ -24,19 +24,16 @@ import "C"
const ()
type statCollector struct {
config Config
cpu *prometheus.CounterVec
cpu *prometheus.CounterVec
}
func init() {
Factories["cpu"] = NewStatCollector
}
// Takes a config struct and prometheus registry and returns a new Collector exposing
// network device stats.
func NewStatCollector(config Config) (Collector, error) {
// cpu stats.
func NewStatCollector() (Collector, error) {
return &statCollector{
config: config,
cpu: prometheus.NewCounterVec(
prometheus.CounterOpts{
Namespace: Namespace,