-- Stundenaggregate der Servergesundheit (Minutenwerte werden nach 14 Tagen verdichtet) CREATE TABLE server_health_hourly ( bucket timestamptz PRIMARY KEY, mspt_avg real NOT NULL, mspt_p95 real NOT NULL, mspt_max real NOT NULL, tps real NOT NULL, players integer NOT NULL, chunks integer NOT NULL, heap_used_mb real NOT NULL, heap_max_mb real NOT NULL, samples integer NOT NULL ); CREATE INDEX stat_snapshots_metric ON stat_snapshots (metric, granularity, uuid, bucket DESC);