Restructure notification code for batching
1 open thread
1 open thread
Compare changes
+ 31
− 8
// EphIdCreator runs as a thread to track ephemeral IDs for users who registered to receive push notifications
@@ -28,14 +29,16 @@ func (nb *Impl) EphIdCreator() {
@@ -28,14 +29,16 @@ func (nb *Impl) EphIdCreator() {
// If the last epoch is further back than the ephemeral ID period, only go back one period for generation
@@ -49,6 +52,22 @@ func (nb *Impl) initCreator() {
@@ -49,6 +52,22 @@ func (nb *Impl) initCreator() {
@@ -61,6 +80,10 @@ func (nb *Impl) addEphemerals(start time.Time) {
@@ -61,6 +80,10 @@ func (nb *Impl) addEphemerals(start time.Time) {