Reputation: 531
so what happening to me is when i open 1 puppeteer instance it would go fast a but the more i open the more time it need to load the URL + fill information is that a normal thing ?
const puppeteer = require('puppeteer');
(async () => {
const browser = await puppeteer.launch();
const page = await browser.newPage();
await page.goto('https://example.com');
await page.screenshot({ path: 'example.png' });
await browser.close();
})();
Upvotes: 4
Views: 2102
Reputation: 13702
Performance of
is highly dependent on the performance of your machine (4 cored , 8 threads , corei7 7700hq
)
On my local setup I could not run more than 10 parallel instances and the performance drop was noticeable the more instances I've launched.
I have faced similar challenge, when I was trying to simulate multiple users using the same application in parallel.
I know: pupeteer (and/or) similar ui-test-automation tools are not good tools for stresstesting your application; or that: there are better tools for that.
Nevertheless, my case was:
HAR
files - that represent network timings of the browser interacting with 10-20 different systemsMy approach was - maybe this helps you:
curl
docker
image on 10 different machines (5-10
dockerized pupeteer tests/machine)curl
Upvotes: 4