package usage // AppStorage is one app's occupancy on one day: deployment-bucket bytes // under the app's prefix, plus its tenant object-store bucket when one is // provisioned. StoreProvisioned distinguishes an empty provisioned store from // no store; StoreUnswept marks a store the pass could not size (bad // credentials, endpoint down) — the dashboard must show "unswept", never 0. type AppStorage struct { BucketBytes int64 `json:"bucket_bytes"` StoreBytes int64 `json:"store_bytes,omitempty"` StoreUnswept bool `json:"store_unswept,omitempty"` StoreProvisioned bool `json:"store_provisioned"` } // StorageDay is usage/storage/.json, keyed "/". type StorageDay struct { V int `json:"v"` // 1 Date string `json:"date"` Apps map[string]AppStorage `json:"apps"` } // StorageDayKey is the bucket key for a day's storage sweep. func StorageDayKey(date string) string { return "usage/storage/" + date + ".json" } // StoragePrefix is the List prefix for storage days. const StoragePrefix = "usage/storage/"