mirror of
https://github.com/pgsty/minio.git
synced 2026-07-20 04:30:26 +03:00
server: Add more elaborate startup messages. (#2731)
These messages based on our prep stage during XL and prints more informative message regarding drive information. This change also does a much needed refactoring.
This commit is contained in:
@@ -18,12 +18,35 @@ package cmd
|
||||
|
||||
import "time"
|
||||
|
||||
// BackendType - represents different backend types.
|
||||
type BackendType int
|
||||
|
||||
// Enum for different backend types.
|
||||
const (
|
||||
Unknown BackendType = iota
|
||||
// Filesystem backend.
|
||||
FS
|
||||
// Multi disk single node XL backend.
|
||||
XL
|
||||
// Add your own backend.
|
||||
)
|
||||
|
||||
// StorageInfo - represents total capacity of underlying storage.
|
||||
type StorageInfo struct {
|
||||
// Total disk space.
|
||||
Total int64
|
||||
// Free available disk space.
|
||||
Free int64
|
||||
// Backend type.
|
||||
Backend struct {
|
||||
// Represents various backend types, currently on FS and XL.
|
||||
Type BackendType
|
||||
|
||||
// Following fields are only meaningful if BackendType is XL.
|
||||
OnlineDisks int // Online disks during server startup.
|
||||
OfflineDisks int // Offline disks during server startup.
|
||||
Quorum int // Minimum disks required for successful operations.
|
||||
}
|
||||
}
|
||||
|
||||
// BucketInfo - represents bucket metadata.
|
||||
|
||||
Reference in New Issue
Block a user