示例#1
0
文件: disk.go 项目: jeichorn/telegraf
func init() {
	inputs.Add("disk", func() telegraf.Input {
		return &DiskStats{ps: &systemPS{}}
	})

	inputs.Add("diskio", func() telegraf.Input {
		return &DiskIOStats{ps: &systemPS{}, SkipSerialNumber: true}
	})
}
示例#2
0
func init() {
	inputs.Add("mem", func() telegraf.Input {
		return &MemStats{ps: &systemPS{}}
	})

	inputs.Add("swap", func() telegraf.Input {
		return &SwapStats{ps: &systemPS{}}
	})
}
示例#3
0
文件: disk.go 项目: beyondpn/telegraf
func init() {
	inputs.Add("disk", func() inputs.Input {
		return &DiskStats{ps: &systemPS{}}
	})

	inputs.Add("diskio", func() inputs.Input {
		return &DiskIOStats{ps: &systemPS{}}
	})
}
示例#4
0
func init() {
	inputs.Add("varnish", func() telegraf.Input {
		return &Varnish{
			run: varnishRunner,
		}
	})
}
示例#5
0
func init() {
	inputs.Add("udp_listener", func() telegraf.Input {
		return &UdpListener{
			UDPPacketSize: UDP_PACKET_SIZE,
		}
	})
}
示例#6
0
文件: ntpq.go 项目: ekini/telegraf
func init() {
	inputs.Add("ntpq", func() telegraf.Input {
		n := &NTPQ{}
		n.runQ = n.runq
		return n
	})
}
示例#7
0
func init() {
	inputs.Add("docker", func() telegraf.Input {
		return &Docker{
			Timeout: internal.Duration{Duration: time.Second * 5},
		}
	})
}
示例#8
0
func init() {
	inputs.Add("mongodb", func() telegraf.Input {
		return &MongoDB{
			mongos: make(map[string]*Server),
		}
	})
}
示例#9
0
func init() {
	inputs.Add("graylog", func() telegraf.Input {
		return &GrayLog{
			client: &RealHTTPClient{},
		}
	})
}
示例#10
0
func init() {
	inputs.Add("iptables", func() telegraf.Input {
		ipt := new(Iptables)
		ipt.lister = ipt.chainList
		return ipt
	})
}
示例#11
0
func init() {
	inputs.Add("statsd", func() telegraf.Input {
		return &Statsd{
			MetricSeparator: "_",
		}
	})
}
示例#12
0
func init() {
	inputs.Add("httpjson", func() telegraf.Input {
		return &HttpJson{
			client: &RealHTTPClient{},
		}
	})
}
示例#13
0
func init() {
	inputs.Add("http_listener", func() telegraf.Input {
		return &HTTPListener{
			ServiceAddress: ":8186",
		}
	})
}
示例#14
0
func init() {
	inputs.Add("influxdb", func() telegraf.Input {
		return &InfluxDB{
			Timeout: internal.Duration{Duration: time.Second * 5},
		}
	})
}
示例#15
0
func init() {
	inputs.Add("kernel", func() telegraf.Input {
		return &Kernel{
			statFile: "/proc/stat",
		}
	})
}
示例#16
0
func init() {
	inputs.Add("raindrops", func() telegraf.Input {
		return &Raindrops{http_client: &http.Client{Transport: &http.Transport{
			ResponseHeaderTimeout: time.Duration(3 * time.Second),
		}}}
	})
}
示例#17
0
文件: statsd.go 项目: ninech/telegraf
func init() {
	inputs.Add("statsd", func() telegraf.Input {
		return &Statsd{
			MetricSeparator:        "_",
			AllowedPendingMessages: defaultAllowPendingMessage,
		}
	})
}
示例#18
0
func init() {
	inputs.Add("hddtemp", func() telegraf.Input {
		return &HDDTemp{
			Address: defaultAddress,
			Devices: []string{"*"},
		}
	})
}
示例#19
0
func init() {
	inputs.Add("zfs", func() telegraf.Input {
		return &Zfs{
			sysctl: sysctl,
			zpool:  zpool,
		}
	})
}
示例#20
0
func init() {
	inputs.Add("udp_listener", func() telegraf.Input {
		return &UdpListener{
			ServiceAddress:         ":8092",
			AllowedPendingMessages: 10000,
		}
	})
}
示例#21
0
func init() {
	inputs.Add("cloudwatch", func() telegraf.Input {
		ttl, _ := time.ParseDuration("1hr")
		return &CloudWatch{
			CacheTTL: internal.Duration{Duration: ttl},
		}
	})
}
示例#22
0
func init() {
	inputs.Add("statsd", func() telegraf.Input {
		return &Statsd{
			ConvertNames:  true,
			UDPPacketSize: UDP_PACKET_SIZE,
		}
	})
}
示例#23
0
func init() {
	inputs.Add("processes", func() telegraf.Input {
		return &Processes{
			execPS:       execPS,
			readProcFile: readProcFile,
		}
	})
}
示例#24
0
文件: cpu.go 项目: cwegener/telegraf
func init() {
	inputs.Add("cpu", func() telegraf.Input {
		return &CPUStats{
			PerCPU:   true,
			TotalCPU: true,
			ps:       &systemPS{},
		}
	})
}
示例#25
0
文件: varnish.go 项目: Wikia/telegraf
func init() {
	inputs.Add("varnish", func() telegraf.Input {
		return &Varnish{
			run:    varnishRunner,
			Stats:  defaultStats,
			Binary: defaultBinary,
		}
	})
}
示例#26
0
func init() {
	inputs.Add("tcp_listener", func() telegraf.Input {
		return &TcpListener{
			ServiceAddress:         ":8094",
			AllowedPendingMessages: 10000,
			MaxTCPConnections:      250,
		}
	})
}
示例#27
0
文件: ping.go 项目: Wikia/telegraf
func init() {
	inputs.Add("ping", func() telegraf.Input {
		return &Ping{
			pingHost:     hostPinger,
			PingInterval: 1.0,
			Count:        1,
			Timeout:      1.0,
		}
	})
}
示例#28
0
func init() {
	c := Chrony{}
	path, _ := exec.LookPath("chronyc")
	if len(path) > 0 {
		c.path = path
	}
	inputs.Add("chrony", func() telegraf.Input {
		return &c
	})
}
示例#29
0
func init() {
	inputs.Add("jolokia", func() telegraf.Input {
		tr := &http.Transport{ResponseHeaderTimeout: time.Duration(3 * time.Second)}
		client := &http.Client{
			Transport: tr,
			Timeout:   time.Duration(4 * time.Second),
		}
		return &Jolokia{jClient: &JolokiaClientImpl{client: client}}
	})
}
示例#30
0
func init() {
	inputs.Add("httpjson", func() telegraf.Input {
		return &HttpJson{
			client: &RealHTTPClient{},
			ResponseTimeout: internal.Duration{
				Duration: 5 * time.Second,
			},
		}
	})
}