Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Action ¶
type Action struct { Action types.ActionType BufferSize uint64 CommitInterval uint64 }
type ApplicationStats ¶
type ApplicationStats struct {
WorkLoad *WorkLoadStats
}
func NewApplicationStats ¶
func NewApplicationStats() *ApplicationStats
type BufferStats ¶
type BufferStats struct { TotalAnnouncedSpace uint64 // 总共许诺出的内存块 TotalAllocatedSpace uint64 // 已经分配出去的内存块 TotalUsedSpace uint64 // 已经使用的内存块 TimeSeriesInMemory uint64 // 为2020年11月18日13:07:24实验新增的统计信息 TotalCommitInterval uint64 // 所有时间序列的总提交时间,便于计算平均提交时间 TsBufferMap map[[16]byte]*TsBufferStats }
func NewBufferStats ¶
func NewBufferStats() *BufferStats
type CacheStats ¶
type CacheStats struct { CacheHit uint64 CacheMiss uint64 CacheSize uint64 LeafCount uint64 NonLeafCount uint64 RecentCacheHit uint64 RecentCacheMiss uint64 LatestUpdateTime time.Time }
func NewCacheStats ¶
func NewCacheStats() *CacheStats
type Performance ¶
type Performance struct {
P float64 // p = \frac{\sum_{j=1}^{q_i} s^{write}_{ij}}{\sum_{j=1}^{q_i} t^{write}_{ij}}
}
type State ¶
type StorageStats ¶
type StorageStats struct { TotalWriteBlocks uint64 TotalReadBlocks uint64 TotalSpan time.Duration LatestUpdateTime time.Time }
func NewStorageStats ¶
func NewStorageStats() *StorageStats
type SystemStats ¶
type SystemStats struct { TsMap map[[16]byte]*Ts TsList []*Ts TsStatsMu sync.RWMutex Buffer *BufferStats BufferMutex sync.RWMutex Cache *CacheStats CacheMutex sync.RWMutex Storage *StorageStats StorageMutex sync.RWMutex }
func NewSystemStats ¶
func NewSystemStats() *SystemStats
func (*SystemStats) GetTs ¶
func (system *SystemStats) GetTs(id [16]byte) *Ts
func (*SystemStats) RandomSampleTs ¶
func (system *SystemStats) RandomSampleTs(count int) []*Ts
type Ts ¶
type TsBufferStats ¶
type TsBufferStats struct { MaxSize uint64 AllocatedSpace uint64 UsedSpace uint64 CommitInterval uint64 Type types.BufferType LatestCommitted time.Time }
func NewTsBufferStats ¶
func NewTsBufferStats() *TsBufferStats
type TsStats ¶
func NewTsStats ¶
func NewTsStats() *TsStats
func (*TsStats) CalculateStatisticsAndGetP ¶
func (*TsStats) CalculateStatisticsAndPerformance ¶
type TsStatsList ¶
type TsStatsList struct { Size int64 Head *TsStatsNode Tail *TsStatsNode MaxSize int64 }
func NewTsStatsList ¶
func NewTsStatsList(maxSize int64) *TsStatsList
func (*TsStatsList) Append ¶
func (list *TsStatsList) Append(data *TsStats)
func (*TsStatsList) Foreach ¶
func (list *TsStatsList) Foreach(f func(stats *TsStats))
type TsStatsNode ¶
type TsStatsNode struct { Data *TsStats Prev *TsStatsNode Next *TsStatsNode }
type WorkLoadStats ¶
type WorkLoadStats struct { TotalReadBytes uint64 TotalWriteBytes uint64 RecentReadBytes uint64 RecentWriteBytes uint64 }
func NewWorkLoadStats ¶
func NewWorkLoadStats() *WorkLoadStats
Click to show internal directories.
Click to hide internal directories.