Add storage comparison to no optimisations
All checks were successful
Build Docker image / build (push) Successful in 59s
Build Golang packages / release (push) Has been skipped

This commit is contained in:
Pieter Hollander 2024-02-22 12:43:29 +01:00
parent 54e8879262
commit be4cb4b1bb
Signed by: pieter
SSH key fingerprint: SHA256:HbX+9cBXsop9SuvL+mELd29sK+7DehFfdVweFVDtMSg

14
main.go
View file

@ -67,6 +67,20 @@ import (
// D1-3, R1-3 4 bytes 010.52 3 031.56
// ---------------------------------------------------------------------------
// Total 137.99
//
// Compared to no optimisations:
//
// Column Column size (bytes) Per month (MB) X Total (MB)
// ---------------------------------------------------------------------------
// Timestamps 8 bytes 21.04
// Values 4 bytes 10.52 21 220.92
// ---------------------------------------------------------------------------
// Total 241.96
//
// Conclusion:
// At the expense of having to create more complicated queries for analysis and visualisation,
// the optimisations save at least 103.97 MB or 1-137.99/241.96 = 43%
// in uncompressed storage space per month.
type Payload struct {
T string `json:"t"` // Timestamp
Dt1 *int `json:"dt1"` // Delivered / imported meter reading tariff 1 (kWh)