6 ms·
I like the change as a general idea but there obviously needs to be a manual override. Like, I don't want websites to access my camera without permission but ob
by lucb1e 10y ago
I like the change as a general idea but there obviously needs to be a manual override. Like, I don't want websites to access my camera without permission but obviously I want to allow some websites to do that. A similar permission could be used here and is perfectly backwards compatible:
1. a tab exceeds its quota and throttling kicks in;
2. you visit the tab to check why it stopped working;
3. you get a permission pop up (like all others) once you visit the tab again, asking you whether you want to allow it unlimited resource usage, noting that it'll decrease battery life of your device.
- josu 10y agoOr just ask for the permission when you first open the page, the same way uber asks for your location. www.foobar.com wants to: "Run in the background unthrottled"
- loco5niner 10y agoI really don't want EVERY website I visit to do this (at least in a pop up).
- windlep 10y agoThe amount of people that will understand what that means is not very substantial. Usually asking for more permissions confuses users as well, people get permission fatigue.
- pmiller2 10y agoThat's less "backward compatible" than the suggestion to pop up a dialog on switching to the page, because the page needs to know to ask for the permission. I'm not sure if that's a good thing or a bad thing. After all, backward compatibility is how we got the semantics of an alert() dialog stopping all JS execution.
- rhizome 10y agoThese days, due to my annoyance with pages reloading themselves when switching to a tab, I'm really not interested in packing more functionality into the whole tab switching mechanism. Like the back button, it should not be visible to web developers.
- woodrowbarlow 10y agoi don't think that would work. request for location doesn't require the page to explicitly indicate a desire, the request is triggered if the page attempts to use the location services of the JS API. sites that want to run unthrottled can't be identified simply by the usage of a certain API, so the developer would need to add something explicitly to their markup to indicate the desire. i want control over the feature regardless of whether or not the site's developer deems it appropriate.
- codedokode 10y agoEvery website would start showing such popup. Now (if you have enabled Javascript) many sites show popup to allow notifications the moment you open them. That is annoying when you search for something in Google and have to click "No" for every new page opened.
- Bartweiss 10y agoThis would be great. At the very least, I'd like the power to un-throttle a tab myself if I decide to do so - even if there's no prompt, it's important to me that I can let a process run full-speed in the background. Losing that would actually decrease the value of Chrome quite a bit for me.
- Brakenshire 10y agoIt could also be a permission granted to a Progressive Web App once the user has decided to install it.
- jklinger410 10y agoPinned tabs would be an easy solution for this. "Don't throttle pinned tabs"
- koheripbal 10y agoA common use-case is tabs that are streaming music. I'm not sure if most users are even aware of pinned tabs.
- CamelCaseName 10y agoI was not, what a great feature!
- philsnow 10y agodidn't they remove pinned tabs a while back, and then re-add them?
- tyingq 10y agoThey are making an exception for tabs that are playing audio. You can see the discussion back and forth, here: https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/-dmrNAFHd-4/discussion https://groups.google.com/a/chromium.org/forum/#!topic/blink... I can see where that will end up though. Everyone who's app was broken by this change will start playing zero volume audio, then the exception will be yanked back. With the web poised to be the new platform for applications, there really needs to be some more thought put into how to accomplish that goal. The chrome devs already sunset some solutions in that space, like the HTML5 app cache. Now this. Nobody likes a constantly moving target.
- bluGill 10y agoNo tab should get the audio exception unless it started playing audio while I was looking at it. (reopen yesterdays tabs counts as looking at it...) If you play audio to get around throttling - you should get zero CPU, not just throttled. If you have work to do in the background that is fine - there is legitimate work to do. However once you are playing audio it must mean the other work is done. What do I know though? I don't normally listen to audio on the web...
- NTripleOne 10y ago>3. I swear to god if I see anything mentioning a battery on a desktop machine with no battery...
- jrockway 10y agoThere's no way to know whether or not it has a battery. Maybe it's on a UPS, for example. All I know is that my desktop runs at about 70W idle vs. 450W fully-loaded. Unnecessary use of the CPU wastes money regardless of whether or not you're using that money to charge a battery.
- jlgaddis 10y agoSites can get your battery level from the browser. IIRC, most of the browsers are going to do away with this functionality soon, however.
- cbhl 10y agoEven on a desktop machine, you don't want tabs spinning in the background (using electricity) if you don't need the work being done. That's bad for your wallet and bad for the environment.
- Ajedi32 10y agoSeems 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 https://developer.mozilla.org/en-US/docs/Web/API/Worker
- MisterKent 10y agoExcept 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.
- Ajedi32 10y agoYeah, 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.
- Oblouk 10y agoI 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.
- fixermark 10y agoFar enough down this road, we're just reimplementing 'renice'. ... which may actually be the right solution.