mirror of
https://github.com/prometheus-community/windows_exporter.git
synced 2026-03-03 09:06:35 +00:00
Lint-fix: Final golint, ignore capitalisation rules
This commit is contained in:
committed by
Calle Pettersson
parent
93904954f4
commit
0121fd6471
@@ -22,6 +22,7 @@ type CPUCollector struct {
|
|||||||
DPCsTotal *prometheus.Desc
|
DPCsTotal *prometheus.Desc
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// NewCPUCollector constructs a new CPUCollector
|
||||||
func NewCPUCollector() (Collector, error) {
|
func NewCPUCollector() (Collector, error) {
|
||||||
const subsystem = "cpu"
|
const subsystem = "cpu"
|
||||||
return &CPUCollector{
|
return &CPUCollector{
|
||||||
|
|||||||
@@ -980,7 +980,7 @@ type Win32_PerfRawData_W3SVC_WebServiceCache struct {
|
|||||||
URICacheMisses uint32
|
URICacheMisses uint32
|
||||||
}
|
}
|
||||||
|
|
||||||
var ApplicationStates = map[uint32]string{
|
var applicationStates = map[uint32]string{
|
||||||
1: "Uninitialized",
|
1: "Uninitialized",
|
||||||
2: "Initialized",
|
2: "Initialized",
|
||||||
3: "Running",
|
3: "Running",
|
||||||
@@ -1261,7 +1261,7 @@ func (c *IISCollector) collect(ch chan<- prometheus.Metric) (*prometheus.Desc, e
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Guages
|
// Guages
|
||||||
for key, label := range ApplicationStates {
|
for key, label := range applicationStates {
|
||||||
isCurrentState := 0.0
|
isCurrentState := 0.0
|
||||||
if key == app.CurrentApplicationPoolState {
|
if key == app.CurrentApplicationPoolState {
|
||||||
isCurrentState = 1.0
|
isCurrentState = 1.0
|
||||||
|
|||||||
@@ -38,6 +38,7 @@ type VmwareCollector struct {
|
|||||||
HostProcessorSpeedMHz *prometheus.Desc
|
HostProcessorSpeedMHz *prometheus.Desc
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// NewVmwareCollector constructs a new VmwareCollector
|
||||||
func NewVmwareCollector() (Collector, error) {
|
func NewVmwareCollector() (Collector, error) {
|
||||||
const subsystem = "vmware"
|
const subsystem = "vmware"
|
||||||
return &VmwareCollector{
|
return &VmwareCollector{
|
||||||
|
|||||||
@@ -6,6 +6,7 @@
|
|||||||
],
|
],
|
||||||
"Exclude": [
|
"Exclude": [
|
||||||
"don't use underscores in Go names",
|
"don't use underscores in Go names",
|
||||||
"exported type .+ should have comment or be unexported"
|
"exported type .+ should have comment or be unexported",
|
||||||
|
"should be"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user