const MainStation, NewStation, ChoiceStation, numStations, newCap, choiceCap, maxQueue, maxPerArtistQ, maxSyncBatch, maxRefreshBatch, foldAfter, queueCooldown, replayGap, maxAheadAir, maxNote, noteCertLife, hideAfter, muteFor, bookMin, bookMax, maxBookedHour, maxKept, maxBooked, maxTrack, recordHeadroom, plainSlot
1const (
2 MainStation = 0
3 NewStation = NumGenres + 1 // the newest newCap ingested tracks
4 ChoiceStation = NumGenres + 2 // the last choiceCap distinct listener picks
5 numStations = ChoiceStation + 1
6 newCap = 300
7 choiceCap = 500
8 maxQueue = 30 // upcoming slots per station
9 maxPerArtistQ = 2 // upcoming slots per artist and station
10 maxSyncBatch = 200
11 maxRefreshBatch = 50
12 foldAfter = 3600 // programmed slots ended this long ago fold into the epoch
13 queueCooldown = 3600 // a listener may queue once per station per hour
14 replayGap = 3 * 3600 // a track picked on a station cannot be picked there again for 3 hours, by anyone
15 maxAheadAir = 7200 // listener-programmed airtime ahead on a station, seconds
16 maxNote = 40 // characters of a dedication
17 noteCertLife = 900 // seconds a moderation certificate may still have to live
18 hideAfter = 3 // distinct reputable listeners (sponsorBlock) reporting a dedication hide it
19 muteFor = 7 * 24 * 3600 // a second hidden dedication within this time mutes its author this long
20 bookMin = 15 * 60 // a pick booked for a time: at least this far ahead
21 bookMax = 24 * 3600 // and at most this far
22 maxBookedHour = 4 // booked picks per station and clock hour (UTC)
23 maxKept = 3 * maxQueue // listener slots a station keeps, aired ones included until they fold
24 maxBooked = maxQueue / 2 // booked picks waiting per station
25 maxTrack = 1200 // the catalog's longest track, seconds
26 recordHeadroom = 1024 // bytes a station record keeps free for the writes that follow a pick
27 plainSlot = 72 // record bytes of a listener slot without a dedication: 25, an address, at most 7 of gap
28)Station ids are stored keys in the permanent data realm (schedules, drops, notes, curator ranks): Main 0, genres 1..NumGenres, New, Choice. A later release must keep them, and add any new station after Choice.