Timeline for Should I persist notification before or after publishing it through Redis pub/sub?
Current License: CC BY-SA 3.0
4 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Jul 1, 2014 at 20:12 | vote | accept | Mik378 | ||
| Jul 1, 2014 at 20:08 | comment | added | miraculixx | looping over 10 notifications is not a problem, but if you do the same for 1000 notifications that will be costly (take a long time and use too much resources). So if you're into 1000s, split them up in batches of 10 - 50 (store within a transaction), then start step 4, store the next 10 - 50, etc. | |
| Jul 1, 2014 at 20:05 | comment | added | Mik378 | Actually, I'm looping over the 10 notifications, and for each iteration, I store the current notification in DB then directly publish it. Do you see a better way? What do you mean by: "by splitting up the users into batches." ? Thanks a lot | |
| Jul 1, 2014 at 20:04 | history | answered | miraculixx | CC BY-SA 3.0 |