storj/satellite/console/projectusagelimits.go
Vitalii Shpital b78f65e83b satellite/console, web/satellite: added object and segment count per project info to new project dashboard
Added new query to get project object and segment count.
Added appropriate object and segment count view for new project dashboard.

Change-Id: I69a2e55442f318c51dc365c0c578b964f2f06c7f
2021-12-01 17:46:07 +02:00

23 lines
716 B
Go

// Copyright (C) 2019 Storj Labs, Inc.
// See LICENSE for copying information.
package console
import "storj.io/common/memory"
// ProjectUsageLimits holds project usage limits and current usage.
type ProjectUsageLimits struct {
StorageLimit int64 `json:"storageLimit"`
BandwidthLimit int64 `json:"bandwidthLimit"`
StorageUsed int64 `json:"storageUsed"`
BandwidthUsed int64 `json:"bandwidthUsed"`
ObjectCount int64 `json:"objectCount"`
SegmentCount int64 `json:"segmentCount"`
}
// UserProjectLimits holds a users storage and bandwidth limits for new projects.
type UserProjectLimits struct {
BandwidthLimit memory.Size `json:"bandwidthLimit"`
StorageLimit memory.Size `json:"storageUsed"`
}