refactor(go): simplify redis realtime projections

This commit is contained in:
lingniu
2026-07-03 13:42:15 +08:00
parent a96490618c
commit c359930009
5 changed files with 207 additions and 70 deletions

View File

@@ -26,12 +26,15 @@ func (s Snapshot) Lightweight() Snapshot {
}
type OnlineStatus struct {
VehicleKey string `json:"vehicle_key"`
VIN string `json:"vin"`
Online bool `json:"online"`
LastSeenMS int64 `json:"last_seen_ms"`
Protocols []envelope.Protocol `json:"protocols,omitempty"`
TTLSeconds int64 `json:"ttl_seconds"`
VehicleKey string `json:"vehicle_key"`
VIN string `json:"vin"`
Protocol envelope.Protocol `json:"protocol,omitempty"`
Online bool `json:"online"`
LastSeenMS int64 `json:"last_seen_ms"`
OfflineAfterMS int64 `json:"offline_after_ms"`
SourceEndpoint string `json:"source_endpoint,omitempty"`
Protocols []envelope.Protocol `json:"protocols,omitempty"`
TTLSeconds int64 `json:"ttl_seconds"`
}
type Config struct {