Documentation ¶
Index ¶
Constants ¶
View Source
const (
// Version is the max version of the config file format supported
Version = 1
)
Variables ¶
View Source
var ( // ErrInvalidVersion is returned when the config file version is not supported. ErrInvalidVersion = errors.New("invalid version") // ErrUnsupportedStorageType is returned when the storage type is not supported. ErrUnsupportedStorageType = errors.New("unsupported storage type") )
Functions ¶
This section is empty.
Types ¶
type Duration ¶
Duration is a wrapper around time.Duration that allows us to unmarshal
func (Duration) MarshalJSON ¶
MarshalJSON marshals the duration as a string
func (*Duration) UnmarshalJSON ¶
UnmarshalJSON unmarshals the duration from a string or a float64
type StorageType ¶
type StorageType string
StorageType is a wrapper around string that allows us to unmarshal
func (*StorageType) UnmarshalJSON ¶
func (s *StorageType) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the storage type from a string and validates it
Click to show internal directories.
Click to hide internal directories.