Help us shape the future of Go! Take the 2026 Go Developer Survey

traffic

package
v1.15.21 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 3, 2026 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ServerTrafficRanking

type ServerTrafficRanking struct {
	ServerId int64
	Download int64
	Upload   int64
	Total    int64
}

type SubscribeTrafficDelta

type SubscribeTrafficDelta struct {
	SubscribeId int64
	Download    int64
	Upload      int64
}

type TotalTraffic

type TotalTraffic struct {
	Download int64
	Upload   int64
}

type TrafficLog

type TrafficLog struct {
	Id          int64     `gorm:"primaryKey"`
	ServerId    int64     `gorm:"index:idx_server_id;not null;comment:Server ID"`
	UserId      int64     `gorm:"index:idx_user_id;not null;comment:User ID"`
	SubscribeId int64     `gorm:"index:idx_subscribe_id;not null;comment:Subscription ID"`
	Download    int64     `gorm:"default:0;comment:Download Traffic"`
	Upload      int64     `gorm:"default:0;comment:Upload Traffic"`
	Timestamp   time.Time `gorm:"default:CURRENT_TIMESTAMP(3);not null;comment:Traffic Log Time"`
}

func (TrafficLog) TableName

func (TrafficLog) TableName() string

type TrafficLogDetailsFilter

type TrafficLogDetailsFilter struct {
	ServerId    int64
	UserId      int64
	SubscribeId int64
	Start       time.Time
	End         time.Time
	Page        int
	Size        int
}

TrafficLogDetailsFilter traffic 明细查询过滤条件

type UserTrafficRanking

type UserTrafficRanking struct {
	UserId      int64
	SubscribeId int64
	Download    int64
	Upload      int64
	Total       int64
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL