elastic / kibana

Your window into the Elastic Stack
https://www.elastic.co/products/kibana
Other
19.76k stars 8.16k forks source link

[Reporting/Canvas] Canvas can not export worksheet to PDF in 7.2.0 #41724

Closed tsullivan closed 5 years ago

tsullivan commented 5 years ago

Describe the bug: Canvas can not export a workpad to PDF in 7.2.0.

This appears to be a resurfacing of https://github.com/elastic/kibana/issues/25052, however this workflow does work in master.

Steps to reproduce:

  1. Create a Canvas workpad with 1 page and 1 element
  2. Export to PDF
  3. Report will fail after 3 attempts, which each time out.

My verbose debug logs show that Reporting navigated to the page and loaded the workpad:

kibana_1         | 2019-07-22T23:44:59.904614300Z {"type":"log","@timestamp":"2019-07-22T23:44:59Z","tags":["reporting","esqueue","worker","debug"],"pid":1,"message":"jyf1a2ni0001ee7ffbbixfya - Claimed job jyf1bti00001ee7ffb44r92u"}
kibana_1         | 2019-07-22T23:44:59.909124100Z {"type":"log","@timestamp":"2019-07-22T23:44:59Z","tags":["reporting","esqueue","worker","debug"],"pid":1,"message":"jyf1a2ni0001ee7ffbbixfya - Starting job jyf1bti00001ee7ffb44r92u"}
kibana_1         | 2019-07-22T23:44:59.946218900Z {"type":"log","@timestamp":"2019-07-22T23:44:59Z","tags":["reporting","screenshots","debug"],"pid":1,"message":"Creating browser driver factory"}
kibana_1         | 2019-07-22T23:45:00.290104300Z {"type":"log","@timestamp":"2019-07-22T23:45:00Z","tags":["reporting","screenshots","debug"],"pid":1,"message":"Driver factory created"}
kibana_1         | 2019-07-22T23:45:00.290818400Z {"type":"log","@timestamp":"2019-07-22T23:45:00Z","tags":["reporting","screenshots","debug"],"pid":1,"message":"opening https://web:8080/kibana/app/canvas#/export/workpad/pdf/workpad-6ea6dc46-a7ad-4275-87c6-7a58669160b2/page/1?forceNow=2019-07-22T23%3A42%3A20.950Z"}
kibana_1         | 2019-07-22T23:45:00.291156100Z {"type":"log","@timestamp":"2019-07-22T23:45:00Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"opening url https://web:8080/kibana/app/canvas#/export/workpad/pdf/workpad-6ea6dc46-a7ad-4275-87c6-7a58669160b2/page/1?forceNow=2019-07-22T23%3A42%3A20.950Z"}
kibana_1         | 2019-07-22T23:45:00.315194000Z {"type":"log","@timestamp":"2019-07-22T23:45:00Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/app/canvas"}
kibana_1         | 2019-07-22T23:45:00.660535500Z {"type":"log","@timestamp":"2019-07-22T23:45:00Z","tags":["security","app-authorization","debug"],"pid":1,"message":"authorizing access to \"canvas\""}
kibana_1         | 2019-07-22T23:45:00.661096300Z {"type":"log","@timestamp":"2019-07-22T23:45:00Z","tags":["security","app-authorization","debug"],"pid":1,"message":"authorized for \"canvas\""}
kibana_1         | 2019-07-22T23:45:01.053654100Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/bundles/app/canvas/bootstrap.js"}
kibana_1         | 2019-07-22T23:45:01.090128200Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","screenshots","browser","debug"],"pid":1,"message":"Refused to execute inline script because it violates the following Content Security Policy directive: \"script-src 'unsafe-eval' 'nonce-4GdBjBbClwgD/+tV'\". Either the 'unsafe-inline' keyword, a hash ('sha256-SHHSeLc0bp6xt4BoVVyUy+3IbVqp3ujLaR+s+kSP5UI='), or a nonce ('nonce-...') is required to enable inline execution.\n"}
kibana_1         | 2019-07-22T23:45:01.236925000Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"No custom headers for data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIzMCIgaGVpZ2h0PSIzOSIgdmlld0JveD0iMCAwIDMwIDM5Ij4gIDxnIGZpbGw9Im5vbmUiIGZpbGwtcnVsZT0iZXZlbm9kZCI+ICAgIDxwb2x5Z29uIGZpbGw9IiNGMDRFOTgiIHBvaW50cz0iMCAwIDAgMzQuNTQ3IDI5LjkyMiAuMDIiLz4gICAgPHBhdGggZmlsbD0iIzM0Mzc0MSIgZD0iTTAsMTQuNCBMMCwzNC41NDY4IEwxNC4yODcyLDE4LjA2MTIgQzEwLjA0MTYsMTUuNzM4IDUuMTgwNCwxNC40IDAsMTQuNCIvPiAgICA8cGF0aCBmaWxsPSIjMDBCRkIzIiBkPSJNMTcuMzc0MiwxOS45OTY4IEwyLjcyMSwzNi45MDQ4IEwxLjQzMzQsMzguMzg5MiBMMjkuMjYzOCwzOC4zODkyIEMyNy43NjE0LDMwLjgzODggMjMuNDA0MiwyNC4zMjY0IDE3LjM3NDIsMTkuOTk2OCIvPiAgPC9nPjwvc3ZnPg=="}
kibana_1         | 2019-07-22T23:45:01.238089900Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/dlls/vendors.style.dll.css"}
kibana_1         | 2019-07-22T23:45:01.239234100Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/node_modules/@elastic/eui/dist/eui_theme_light.css"}
kibana_1         | 2019-07-22T23:45:01.239968700Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/node_modules/@kbn/ui-framework/dist/kui_light.css"}
kibana_1         | 2019-07-22T23:45:01.247383700Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/bundles/light_theme.style.css"}
kibana_1         | 2019-07-22T23:45:01.248172200Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/bundles/commons.style.css"}
kibana_1         | 2019-07-22T23:45:01.250726600Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/bundles/canvas.style.css"}
kibana_1         | 2019-07-22T23:45:01.253292700Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/vega/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.254094000Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/timelion/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.255911200Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/tile_map/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.256640700Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/tagcloud/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.257289400Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/table_vis/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.258030500Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/region_map/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.258722300Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/metrics/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.261139900Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/metric_vis/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.291757700Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/markdown_vis/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.297789400Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/kibana/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.299836900Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/inspector_views/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.301878500Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/input_control_vis/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.303092600Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/data/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.304571100Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/console/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.305857800Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/upgrade_assistant/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.308549000Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/cross_cluster_replication/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.309830600Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/remote_clusters/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.310981300Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/rollup/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.334004200Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/infra/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.336630200Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/index_lifecycle_management/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.342259800Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/index_management/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.348445100Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/license_management/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.349981500Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/canvas/style/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.350721200Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/maps/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.351373700Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/code/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.352018900Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/apm/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.352632900Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/watcher/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.353268700Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/ml/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.353876000Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/searchprofiler/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.355555700Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/security/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.356161000Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/spaces/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.356787400Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/monitoring/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.399561800Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/css/plugins/graph/index.light.css"}
kibana_1         | 2019-07-22T23:45:01.401583000Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/built_assets/dlls/vendors.bundle.dll.js"}
kibana_1         | 2019-07-22T23:45:01.405837200Z {"type":"log","@timestamp":"2019-07-22T23:45:01Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"waitForSelector .application"}
kibana_1         | 2019-07-22T23:45:02.036120100Z {"type":"log","@timestamp":"2019-07-22T23:45:02Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/ui/fonts/inter_ui/Inter-UI-Regular.woff2"}
kibana_1         | 2019-07-22T23:45:05.441659500Z {"type":"log","@timestamp":"2019-07-22T23:45:05Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/bundles/commons.bundle.js"}
kibana_1         | 2019-07-22T23:45:06.134419200Z {"type":"log","@timestamp":"2019-07-22T23:45:06Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/bundles/canvas.bundle.js"}
kibana_1         | 2019-07-22T23:45:09.183447500Z {"type":"log","@timestamp":"2019-07-22T23:45:09Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/translations/en.json"}
kibana_1         | 2019-07-22T23:45:11.548073300Z {"type":"log","@timestamp":"2019-07-22T23:45:11Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/api/security/v1/me"}
kibana_1         | 2019-07-22T23:45:11.554199300Z {"type":"log","@timestamp":"2019-07-22T23:45:11Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/api/spaces/space"}
kibana_1         | 2019-07-22T23:45:11.555836000Z {"type":"log","@timestamp":"2019-07-22T23:45:11Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/api/canvas/workpad/workpad-6ea6dc46-a7ad-4275-87c6-7a58669160b2"}
kibana_1         | 2019-07-22T23:45:11.907857300Z {"type":"log","@timestamp":"2019-07-22T23:45:11Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/ui/fonts/inter_ui/Inter-UI-Medium.woff2"}
kibana_1         | 2019-07-22T23:45:12.095675400Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"waitForSelector .application resolved"}
kibana_1         | 2019-07-22T23:45:12.096174500Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","screenshots","debug"],"pid":1,"message":"injecting custom css"}
kibana_1         | 2019-07-22T23:45:12.154743200Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/api/xpack/v1/info"}
kibana_1         | 2019-07-22T23:45:12.209659000Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","screenshots","debug"],"pid":1,"message":"waiting for elements or items count attribute; or not found to interrupt"}
kibana_1         | 2019-07-22T23:45:12.213309800Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"waitForSelector [data-shared-item],[data-shared-items-count]"}
kibana_1         | 2019-07-22T23:45:12.214944500Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"waitForSelector [data-test-subj=\"euiToastHeader\"]"}
kibana_1         | 2019-07-22T23:45:12.356794300Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/api/canvas/workpad-structures/workpad-6ea6dc46-a7ad-4275-87c6-7a58669160b2"}
kibana_1         | 2019-07-22T23:45:12.363324100Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/api/interpreter/fns"}
kibana_1         | 2019-07-22T23:45:12.531501900Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","screenshots","browser","debug"],"pid":1,"message":"JSHandle@error"}
kibana_1         | 2019-07-22T23:45:12.564176200Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/api/interpreter/fns"}
kibana_1         | 2019-07-22T23:45:12.739177100Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/api/interpreter/fns"}
kibana_1         | 2019-07-22T23:46:10.915907700Z {"type":"log","@timestamp":"2019-07-22T23:46:10Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"Using custom headers for https://web:8080/kibana/api/telemetry/v2/clusters/_stats"}
kibana_1         | 2019-07-22T23:46:11.961157700Z {"type":"log","@timestamp":"2019-07-22T23:46:11Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"No custom headers for https://telemetry.elastic.co/xpack/v2/send"}
kibana_1         | 2019-07-22T23:46:12.212689800Z {"type":"log","@timestamp":"2019-07-22T23:46:12Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","debug"],"pid":1,"message":"No custom headers for https://telemetry.elastic.co/xpack/v2/send"}
kibana_1         | 2019-07-22T23:46:59.849035500Z {"type":"log","@timestamp":"2019-07-22T23:46:59Z","tags":["reporting","esqueue","worker","warn"],"pid":1,"message":"jyf1a2ni0001ee7ffbbixfya - Timeout processing job jyf1bti00001ee7ffb44r92u"}
kibana_1         | 2019-07-22T23:46:59.849096400Z {"type":"log","@timestamp":"2019-07-22T23:46:59Z","tags":["reporting","esqueue","worker","warn"],"pid":1,"message":"jyf1a2ni0001ee7ffbbixfya - Timeout on job jyf1bti00001ee7ffb44r92u"}
kibana_1         | 2019-07-22T23:46:59.854987600Z {"type":"log","@timestamp":"2019-07-22T23:46:59Z","tags":["reporting","queue","worker","debug"],"pid":1,"message":"Job timeout exceeded: (jyf1bti00001ee7ffb44r92u)"}
kibana_1         | 2019-07-22T23:46:59.864709000Z {"type":"log","@timestamp":"2019-07-22T23:46:59Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","error"],"pid":1,"message":"waitForSelector [data-shared-item],[data-shared-items-count] failed on https://web:8080/kibana/app/canvas#/export/workpad/pdf/workpad-6ea6dc46-a7ad-4275-87c6-7a58669160b2/page/1?forceNow=2019-07-22T23:42:20.950Z"}

Therefore, it could be a problem with the expected data-shared-item attributes on the visualization

tsullivan commented 5 years ago

2019-07-22T23:46:59.864709000Z {"type":"log","@timestamp":"2019-07-22T23:46:59Z","tags":["reporting","browser-driver","chromium-driver-factory","headless-chromium-driver","error"],"pid":1,"message":"waitForSelector [data-shared-item],[data-shared-items-count] failed on https://web:8080/kibana/app/canvas#/export/workpad/pdf/workpad-6ea6dc46-a7ad-4275-87c6-7a58669160b2/page/1?forceNow=2019-07-22T23:42:20.950Z"}

When I load that URL in my browser, I see this: image

It has just enough stuff on the page to make the Reporting browser think it is on the right place, and it's not seeing any toast error that would cause a meaningful failure.

The workpad loads OK when I navigate to it from the workpad loader.

This probably explains something I didn't understand in the logs: 2019-07-22T23:45:12.531501900Z {"type":"log","@timestamp":"2019-07-22T23:45:12Z","tags":["reporting","screenshots","browser","debug"],"pid":1,"message":"JSHandle@error"}

Initially, when I saw that line I mistaked it for the: Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'nonce-

tsullivan commented 5 years ago

The logs are correct in saying the data-shared-item data on the page could not be found: image

tsullivan commented 5 years ago

cc @elastic/kibana-canvas

tsullivan commented 5 years ago

I've seen when running 7.2.0 from source, the error shown as the failure reason is different. When running in source, Reporting shows the error message found in the browser JS console and gave that as the failure reason.

When running a build (Docker, with Kibana behind a proxy), I get a meaningless "Max attempts" error

tsullivan commented 5 years ago

7.2.0-specific bug. Closing via https://github.com/elastic/kibana/pull/41298

Eniqmatic commented 5 years ago

Hi Tim,

Can you confirm this issue is now resolved? I'm stuck on 7.2 with none of my PDF reports working and awaiting the fix for this desperately.

Thanks

tsullivan commented 5 years ago

Hi @Eniqmatic https://github.com/elastic/kibana/pull/41298 is targeting 7.2.1, which is the next patch coming up in the 7.2 minor. We don't announce release dates, but it'll be coming soon.

Eniqmatic commented 5 years ago

Hi Tim,

I don't see this issue resolved in the change log for 7.3, would I assume it is not yet fixed in that version?

Thanks

shaunmcgough commented 5 years ago

@Eniqmatic it likely is not fixed, and we're tracking a number of issues around PDFs in Kibana

39418

41405

39418

We suspect that this is a combination effort and that some PDF functionality will be impacted in 7.3.

tsullivan commented 5 years ago

The release notes don't mention this as a resolved Reporting issue. The issue Reporting issue happened because Canvas was crashing when rendering its export view: https://github.com/elastic/kibana/pull/41298

The export view that I looked up to find the page crash can be found in the debug logs of Kibana. Search for opening url. For example:

{"type":"log","@timestamp":"2019-08-01T20:57:40Z","tags":["reporting","screenshots","debug"],"pid":1,"message":"opening https://web:8080/kibana/app/canvas#/export/workpad/pdf/workpad-cada9628-a635-4e69-a63d- e7955acfdbfc/page/6?forceNow=2019-08-01T20%3A55%3A38.395Z"}

We're working on making this kind of message more evident in the logs, since it was necessary to try to run that URL to find that the Canvas page was crashing. And we're working on the other stability and performance issues that Shaun listed

tsullivan commented 5 years ago

Also, my understanding is the Canvas fix should be listed in the release notes for 7.2.1: https://www.elastic.co/guide/en/kibana/7.2/release-notes-7.2.1.html

I'll check if this was an oversight

Eniqmatic commented 5 years ago

Thanks Shaun and Tim. Hopefully this is implemented in 7.2.1, this is killing our reports at the moment and we are having to run a bunch of things manually for many many weeks now.

MarianMM commented 5 years ago

@tsullivan, Thank you for looking into this. Please let us know if this is fixed in 7.2.1. Thank you for your confirmation.

tsullivan commented 5 years ago

@MarianMM confirmed.

The fix in Canvas closes this issue because Canvas no longer crashes when Reporting scans the page for PDF.

If customers are still having problems with any part of Reporting in any other version, please turn on debug logs in Kibana and look for the parts that show what the Reporting headless browser is doing on the server side of Kibana. You'll find:

What's always harder to find and detect are environmental problem with Reporting: not able to connect to Kibana webserver due to firewalling, not able to log in due to invalid auth cache, trying to open a saved object but getting a 404, not enough RAM or CPU on the machine for Chromium, etc.