News for hackers. Stuff that matters.
Re:Chrome will aggressively throttle background tabs by Ajedi32 on Tuesday January 24, 2017 @12:52PM (#13473669)
Seems like the current solution they're advocating for is for sites to do background processing in a [Worker][1].

This seems like a step towards the way things work with mobile apps currently, where the app's main thread gets suspended when its not in the foreground, and background processing happens in separate threads which the user has some degree of control over.

Edit: I meant regular `Worker`s, not `ServiceWorker`s.

[1]: https://developer.mozilla.org/en-US/docs/Web/API/Worker

Re:Chrome will aggressively throttle background tabs by MisterKent on Tuesday January 24, 2017 @02:07PM (#13474432)
Except it should probably be web workers that are unthrottled. However, in the current implementation Web workers do get throttled. Service workers are supposed to be for networking and offline applications, not doing cpu related things. As such, service worker lifetimes are really messy since they don't have real guarantees as to if they will randomly restart.
Re:Chrome will aggressively throttle background tabs by Oblouk on Tuesday January 24, 2017 @03:14PM (#13475031)
I am having a hard time finding where it states that web workers are treated the same as threads managing visual content. Currently timers in background threads are throttled to 1sec minimum interval however workers are not bound by this constraint. I may just be missing something, but I sure hope not. This would adversely impact many games and applications rendering many of them unusable without the web worker exclusion.
Re:Chrome will aggressively throttle background tabs by Ajedi32 on Tuesday January 24, 2017 @02:18PM (#13474540)
Yeah, sorry. I keep conflating service workers with the larger concept of web workers. For more intensive tasks you'd definitely use a regular dedicated worker, not a service worker.