@seanc07 @lukegibson93 in the age of Workload Units, in app notifications should be avoided. They are a huge drain on WU resources and should not be added unless it is a mission critical feature.
Reasons…
- Each time you create the entry in the DB for a notification you are charged WUs, and that adds up
- Each time a user opens a page in the app the notifications, likely living in the header are needed to be fetched from the DB, which adds up QUICKLY…just think about a user who logs in on page A, navigates to page B, then goes to page C and then to page D before logging out…that user just cost you 4 searches of the DB, which at a minimum is 0.3 WUs, and likely around 1-2WUs for each, about 1.2-8 WUs for a visit to 4 pages, which could be much higher if they have notifications to shown (ie: if you remove already seen notifications it will cost less, but if you show all past notifications as well, that is EXPENSIVE).
- Each time the user clicks a notification to change its status from not seen to seen, it costs at least 0.6WUs.