node.go 1.9 KB

12345678910111213141516171819202122232425
  1. package kubemodel
  2. import "time"
  3. // @bingen:generate:Node
  4. type Node struct {
  5. UID string `json:"uid"` // @bingen:field[version=1]
  6. ClusterUID string `json:"clusterUid"` // @bingen:field[version=1]
  7. ProviderResourceUID string `json:"providerResourceUid"` // @bingen:field[version=1]
  8. Name string `json:"name"` // @bingen:field[version=1]
  9. Labels map[string]string `json:"labels,omitempty"` // @bingen:field[version=1]
  10. Annotations map[string]string `json:"annotations,omitempty"` // @bingen:field[version=1]
  11. Start time.Time `json:"start"` // @bingen:field[version=1]
  12. End time.Time `json:"end"` // @bingen:field[version=1]
  13. CpuMillicoreSecondsAllocated uint64 `json:"cpuMillicoreSecondsAllocated"` // @bingen:field[version=1]
  14. RAMByteSecondsAllocated uint64 `json:"ramByteSecondsAllocated"` // @bingen:field[version=1]
  15. // PublicIPSeconds represents the cumulative public IP allocation (count × seconds) for this node.
  16. // Calculated as: number of ExternalIP addresses from Kubernetes node Status.Addresses × window duration in seconds.
  17. // Used for cost attribution of public IP addresses associated with the node.
  18. PublicIPSecondsAllocated uint64 `json:"publicIpSecondsAllocated"` // @bingen:field[version=1]
  19. CpuMillicoreUsageAverage uint64 `json:"cpuMillicoreUsageAverage"` // @bingen:field[version=1]
  20. CpuMillicoreUsageMax uint64 `json:"cpuMillicoreUsageMax"` // @bingen:field[version=1]
  21. RAMByteUsageAverage uint64 `json:"ramByteUsageAverage"` // @bingen:field[version=1]
  22. RAMByteUsageMax uint64 `json:"ramByteUsageMax"` // @bingen:field[version=1]
  23. }