This commit is contained in:
2026-03-22 22:31:29 +01:00
parent 97d4a990a8
commit 6f87742882
16 changed files with 371 additions and 107 deletions
+11
View File
@@ -25,6 +25,7 @@ type ProfileData struct {
Timestamp time.Time `json:"timestamp"`
Rank int `json:"rank"`
Upload string `json:"upload"`
UploadBytes int64 `json:"upload_bytes"`
CurrentUpload string `json:"current_upload"`
CurrentDownload string `json:"current_download"`
Points int `json:"points"`
@@ -43,3 +44,13 @@ type State struct {
db *sql.DB
client *http.Client
}
// CompactHistory represents an optimized, columnar history format.
type CompactHistory struct {
Owner string `json:"owner"`
Timestamp []int64 `json:"t"`
Rank []int `json:"r"`
Upload []float64 `json:"u"`
Points []int `json:"p"`
Seeding []int `json:"s"`
}