Closed
Bug 921678
Opened 11 years ago
Closed 6 years ago
[Notifications] "clear all" opens apps
Categories
(Firefox OS Graveyard :: Gaia::System, defect)
Tracking
(Not tracked)
RESOLVED
WONTFIX
People
(Reporter: jrburke, Unassigned)
References
Details
(Whiteboard: [systemsfe])
Noticed while testing the email app: Email app background syncs for new messages, if it finds a new one, sends a notification, then closes itself. In the Notifications list, if Clear All is pressed, it triggers a notification message event for the onclose to the email app. Since the email app is closed, the email app is started up in the background. Since the notification is not for a click, the email app does nothing, just sits in the background. This seems wasteful. It also seems that most apps will not care if a notification is closed. I would prefer to not get notified on any close events. It would be good to do a survey of apps to see which ones care about close. It is also weird that an onclick also triggers an onclose notification. End result, close seems to be triggered too much to be useful, creates more work for apps to handle, and in this particular case, uses up battery/memory. If I had an option to do so, I would not want any close events for the email app. If a need for onclose notifications is discovered, perhaps it is better for the app to indicate on the `new Notification` if it cares about onclose and only do onclose work in those cases.
Comment 1•11 years ago
|
||
Why can't not defining onclose be enough to solve this problem?
Whiteboard: [systemsfe]
Reporter | ||
Comment 2•11 years ago
|
||
The app is closed when the notification action occurs, so the navigator.mozSetMessageHandler('notification', function(){}) entry point is called.
Comment 3•11 years ago
|
||
Okay. How critical is this? I'm trying to figure out if this is a blocker for 1.2 or not.
Blocks: b2g-notifications
Reporter | ||
Comment 4•11 years ago
|
||
Severity of the bug: Nothing crashes outright, but it starts up any app that had a notification in the tray that was not already running. So if there is an SMS, calendar, and email notification, all three will get started up. There could be some OOM results because of the bulk app starting, probably evicting apps the user was actually wanting to use at the time? I am not conversant with the OOM rules, but that the worst likely scenario I can think of. This is probably not some new behavior, so not a regression. Just may be more noticeable as more apps like email use notifications. On how to possibly fix it: A short term fix may be to not open apps for the close notification, only trigger close notifications for apps that are already running and have a .onclose attached to the Notification object, or have a mozSetMessageHandler set. I do not know the code though, so this may not be helpful to suggest. On the overall issue though, I would support not firing mozSetMessageHandler for close events at all.
Comment 5•11 years ago
|
||
Gregor - Reading above, do you think this is worth noming? I'm in the middle on this one. In one sense, this sounds bad because we're chewing up memory resources easily on a clear all operation. It might confuse the user as well that they see a bunch of these apps magically running as well. Then again, we already have a known bug for a while that's similar to this with the calendar app, in that appears in the background do the system message handler.
Flags: needinfo?(anygregor)
Comment 6•11 years ago
|
||
(In reply to Jason Smith [:jsmith] from comment #5) > Gregor - Reading above, do you think this is worth noming? > > I'm in the middle on this one. In one sense, this sounds bad because we're > chewing up memory resources easily on a clear all operation. It might > confuse the user as well that they see a bunch of these apps magically > running as well. Then again, we already have a known bug for a while that's > similar to this with the calendar app, in that appears in the background do > the system message handler. At this point I think it's a nice to have but I don't think we should block on it. Lets put it on the radar for 1.3.
Flags: needinfo?(anygregor) → needinfo?(pdolanjski)
Comment 7•11 years ago
|
||
I agree with Gregor. I'll pull it into our backlog, but not blocking.
Flags: needinfo?(pdolanjski)
Comment 8•6 years ago
|
||
Firefox OS is not being worked on
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•