Documentation
¶
Overview ¶
Package utilization implements the Utilization spec, available at https://source.datanerd.us/agents/agent-specs/blob/master/Utilization.md
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // SampleData contains sample utilization data useful for testing. SampleData = Data{ MetadataVersion: metadataVersion, LogicalProcessors: &sampleLogicProc, RAMMiB: &sampleRAMMib, Hostname: "my-hostname", } )
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
DetectAWS bool
DetectAzure bool
DetectGCP bool
DetectPCF bool
DetectDocker bool
DetectKubernetes bool
LogicalProcessors int
TotalRAMMIB int
BillingHostname string
}
Config controls the behavior of utilization information capture.
type Data ¶
type Data struct {
MetadataVersion int `json:"metadata_version"`
// Although `runtime.NumCPU()` will never fail, this field is a pointer
// to facilitate the cross agent tests.
LogicalProcessors *int `json:"logical_processors"`
RAMMiB *uint64 `json:"total_ram_mib"`
Hostname string `json:"hostname"`
FullHostname string `json:"full_hostname,omitempty"`
Addresses []string `json:"ip_address,omitempty"`
BootID string `json:"boot_id,omitempty"`
Config *override `json:"config,omitempty"`
Vendors *vendors `json:"vendors,omitempty"`
}
Data contains utilization system information.
Source Files
¶
- addresses.go
- aws.go
- azure.go
- fqdn.go
- gcp.go
- pcf.go
- provider.go
- utilization.go
Click to show internal directories.
Click to hide internal directories.