Wire NowPlayingStats to live aggregates: add SQL track duration column, stats endpoint, and duration backfill
This commit is contained in:
@@ -15,6 +15,10 @@ public class TrackEntity : BaseEntity, IEntity
|
||||
public required string TrackName { get; set; }
|
||||
public string? OriginalFileName { get; set; }
|
||||
public int TrackNumber { get; set; } = 1;
|
||||
// Audio runtime in seconds, extracted by the processor at upload (AudioBinary.Duration) and
|
||||
// persisted here so aggregate queries (e.g. total mix runtime) read it from SQL rather than the
|
||||
// vault. Nullable: rows that predate this column are valid until the one-time backfill populates them.
|
||||
public double? DurationSeconds { get; set; }
|
||||
public long? ReleaseId { get; set; }
|
||||
public ReleaseEntity? Release { get; set; }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user