--
You received this message because you are subscribed to the Google Groups "headless-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to headless-dev+unsubscribe@chromium.org.
To post to this group, send email to headle...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/headless-dev/565099f2-5496-45cd-b48b-0ead0626f3a7%40chromium.org.
Using either a custom proxy or C++ ProtocolHandlers you could return stub 1x1 pixel images (etc...) or even block them entirely.We are working on adding programmatic control over when frames are produced. Currently headless chrome is still trying to render at 60 fps which is rather wasteful. Many pages do need a few frames (maybe 10-20) to render properly (due to usage of requestAnimationFrame and animation triggers) but we expect there are a lot of CPU savings to be had here.On 8 March 2017 at 17:39, Georgios Diamantopoulos <geor...@gmail.com> wrote:Hey fellas,I love this project! Thank you all for working on it.I'm looking to have a "farm" of headless agents at the ready to drive my tests, and we'd like to optimize the headless build to minimize the usage of resources (CPU+memory).We're not particularly interested in anything more than rendering the DOM and executing any JS on the page so it's functional.Images, fonts, videos etc are uninteresting so disabling loading of images and fonts would be the obvious starting point.What else can we do to minimize the resource expenditure in this scenario?- Are there features we can disable on the code level?- Can we target x86 to lower the mem usage? (would that be a significant cut?)- Are there any hacks we can do using the embedder API to optimize the network loop and/or message loop?- Should we aim to run multiple agents in a single process or one agent/process and multiple processes?ANY suggestions very welcome, thank you in advance.Georgios
--
You received this message because you are subscribed to the Google Groups "headless-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to headless-dev...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/headless-dev/CAEykOLEpWmAZCrT9FFbPvxF7ATO7_G88JycaZm3LJrGTj%2B%2B-Dw%40mail.gmail.com.
You received this message because you are subscribed to a topic in the Google Groups "headless-dev" group.
To unsubscribe from this topic, visit https://groups.google.com/a/chromium.org/d/topic/headless-dev/f_tQUs__Yqw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to headless-dev...@chromium.org.
To post to this group, send email to headle...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/headless-dev/CAPuLcztkgAhDzf-NDKVLN%2BUN3Vft3dVxv1qEcAHCX8fs4zRixg%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/headless-dev/CAEykOLEhLhZ%2BhuB6zaWjJTL3oLJ%2B0N2EM8pf8Cd6TRvJ4qtZkw%40mail.gmail.com.
I think that you could actually use cgroups to put resource limits per render process. That way, you can open as many tabs as you’d like while keeping resource utilization linear. That’s a bit outside my expertise in cgroups though, so I can’t point you to exactly how to do it.
For those suggesting Docker, this is also a great option and actually uses cgroups under the hood, provides a much nicer wrapper, but offers slightly less control. If you do go that route, keep in mind that you will need to increase the shared memory size for your containers “--shm-size” as well as override the default seccomp profile so that sandboxing will still work. You can find a working seccomp profile here: https://github.com/jessfraz/dotfiles/blob/master/etc/docker/seccomp/chrome.json
--
You received this message because you are subscribed to the Google Groups "headless-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to headless-dev...@chromium.org.
To post to this group, send email to headle...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/headless-dev/66b5d584-5b78-4692-9c29-8b6ec0fd93b5%40chromium.org.