Reputation: 31
I am using URL link to get a whole grafana dashboard png report however for some complex dashboard I am getting timeout error.
Link to get report
http://HOST_IP:3000/render/d/ybG8WXyZz/dashboard-1?orgId=1&width=1800&height=900&kiosk=tv&from=now-1h&to=now&var-machine=&var-ideal=12
Error details
"stack":"TimeoutError: Navigation timeout of 30000 ms exceeded\n at /usr/src/app/node_modules/puppeteer/lib/LifecycleWatcher.js:142:21\n -- ASYNC --\n at Frame.<anonymous> (/usr/src/app/node_modules/puppeteer/lib/helper.js:111:15)\n at Page.goto (/usr/src/app/node_modules/puppeteer/lib/Page.js:675:49)\n at Page.<anonymous> (/usr/src/app/node_modules/puppeteer/lib/helper.js:112:23)\n at Browser.<anonymous> (/usr/src/app/build/browser/browser.js:154:28)\n at Generator.next (<anonymous>)\n at /usr/src/app/build/browser/browser.js:7:71\n at new Promise (<anonymous>)\n at __awaiter (/usr/src/app/build/browser/browser.js:3:12)\n at /usr/src/app/build/browser/browser.js:152:47\n at NoOpBrowserTiming.<anonymous> (/usr/src/app/build/browser/browser.js:27:26)\n -- ASYNC --\n at Page.<anonymous> (/usr/src/app/node_modules/puppeteer/lib/helper.js:111:15)\n at Browser.<anonymous> (/usr/src/app/build/browser/browser.js:154:28)\n at Generator.next (<anonymous>)\n at /usr/src/app/build/browser/browser.js:7:71\n at new Promise (<anonymous>)\n at __awaiter (/usr/src/app/build/browser/browser.js:3:12)\n at /usr/src/app/build/browser/browser.js:152:47\n at NoOpBrowserTiming.<anonymous> (/usr/src/app/build/browser/browser.js:27:26)\n at Generator.next (<anonymous>)\n at /usr/src/app/build/browser/browser.js:7:71","level":"error","message":"Request failed"}
Can someone help me to understand where to change default 30000ms timeout ? I am using docker version of image renderer.
Upvotes: 0
Views: 2995
Reputation: 5702
You need to increase the timeout for puppeteer.
I would start altering following line 144 in browser.ts which currently states
await page.goto(options.url, { waitUntil: 'networkidle0' });
to
await page.goto(options.url, { waitUntil: 'networkidle0', timeout: 3000000 });
Rebuild the grafana image renderer, deploy it and see if that fixed it.
Source
Upvotes: 1