status.go 1.1 KB

1234567891011121314151617181920212223242526272829303132
  1. package kubecost
  2. import "time"
  3. // ETLStatus describes ETL metadata
  4. type ETLStatus struct {
  5. Coverage Window `json:"coverage"`
  6. Progress float64 `json:"progress"`
  7. RefreshRate string `json:"refreshRate"`
  8. StartTime time.Time `json:"startTime"`
  9. UTCOffset string `json:"utcOffset"`
  10. Backup *DirectoryStatus `json:"backup,omitempty"`
  11. }
  12. // DirectoryStatus describes metadata of a directory of files
  13. type DirectoryStatus struct {
  14. Path string `json:"path"`
  15. Size string `json:"size"`
  16. LastModified time.Time `json:"lastModified"`
  17. FileCount int `json:"fileCount"`
  18. Files []FileStatus `json:"files"`
  19. }
  20. // FileStatus describes the metadata of a single file
  21. type FileStatus struct {
  22. Name string `json:"name"`
  23. Size string `json:"size"`
  24. LastModified time.Time `json:"lastModified"`
  25. Details map[string]string `json:"details,omitempty"`
  26. Errors []string `json:"errors,omitempty"`
  27. Warnings []string `json:"warnings,omitempty"`
  28. }