This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 27108 - Push API should be allowed without dependency on service worker
Summary: Push API should be allowed without dependency on service worker
Status: RESOLVED MOVED
Alias: None
Product: WebAppsWG
Classification: Unclassified
Component: Push API (show other bugs)
Version: unspecified
Hardware: PC Windows NT
: P2 normal
Target Milestone: ---
Assignee: Bryan Sullivan
QA Contact: public-webapps-bugzilla
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-10-20 15:52 UTC by Shijun Sun
Modified: 2015-10-06 11:37 UTC (History)
6 users (show)

See Also:


Attachments

Description Shijun Sun 2014-10-20 15:52:24 UTC
Open a bug to track the topic on the mailing list.
http://lists.w3.org/Archives/Public/public-webapps/2014OctDec/0179.html 

When the "push client" can handle generic actions (such as posting a toast notifications) waking up the browser (or a subset of it) and let service workers to display each notification might not be the best practice from performance perspective, especially when the user does not want to pick up each incoming video call or read each incoming emails right away.  The Push API spec should allow the web developers to have flexibility to leverage the generic actions, or rely on a service worker, or maybe do both.

I expect the generic message types should be scoped to a very small set.  Toast notification with a text message and an optional image should be a good starting point.  This will also lead to extensions to existing API.  For example, we should allow a webapp to construct a PushRegistrationManager based on a valid registrationId it got previously.  We should think through the details in the WG.

BTW, Martin Thomson mentioned another scenario [1] in the mailing list that can also benefit without having the service worker dependency.

[1] http://lists.w3.org/Archives/Public/public-webapps/2014OctDec/0140.html
Comment 1 Anne 2014-10-20 15:58:34 UTC
What's the problem with requiring a service worker?
Comment 2 Arthur Barstow 2014-10-20 16:05:48 UTC
[ Bryan, Eduardo, Michael - rather than track Push API bugs via Bugzilla and Github Issues, perhaps you should converge on one (probably Github). ]
Comment 3 Chris Wilson 2014-10-20 16:06:47 UTC
Even more directly - what's the Push "client", if not code inside the SW?  How do you "handle" actions without somewhere to hang that code?
Comment 4 Shijun Sun 2014-10-20 16:15:24 UTC
(In reply to Chris Wilson from comment #3)
> Even more directly - what's the Push "client", if not code inside the SW? 
> How do you "handle" actions without somewhere to hang that code?

Based on Fig. 1 of the spec, the client is implemented in the UA or the system it runs on.
Comment 5 Shijun Sun 2014-10-21 04:47:53 UTC
(In reply to Arthur Barstow from comment #2)
> [ Bryan, Eduardo, Michael - rather than track Push API bugs via Bugzilla and
> Github Issues, perhaps you should converge on one (probably Github). ]

I'll copy the bug to Github.  Thanks!
Comment 6 Arthur Barstow 2015-10-06 11:37:31 UTC
This bug has been moved to a Github issue <https://github.com/w3c/push-api/issues/84>.