Generation URL not working

reporting

(Bwgriffith) #1

I have reporting setup in a shield environment. I am about to create a report via the "Document Generation" printable button.

However, when I create a report via the Generation URL and try to access that URL I receive an error:

{"statusCode":404,"error":"Not Found"}

Any ideas?


404 error when pasting Generation URL to browser
(Mark Walkom) #2

What does your browser console show? Anything in KB and ES logs? What version are you on?


(Daan) #3

Hi,

I am facing a similar issue with getting a 404 statusCode error when using the Generation URL. If I use the button 'Printable PDF' then I can download a pdf report under Settings > Reporting. When copying the Generation URL and visiting the URL in the browser I get {"statusCode":404,"error":"Not Found"}.

My environment:

  • Elasticsearch 2.4.0 on http://localhost:9210/
  • Kibana 4.6.1 on http://localhost:5611
  • Reporting 2.4.2
  • Own hardware, Windows 10
  • No proxy between between components.
    Because Elasticsearch and Kibana are not working on the default ports, I set in kibana.yml 'server.port: 5611' and 'server.host: "localhost"'.

Neither Elasticsearch nor Kibana shows anything in the console when visiting the Generation URL.

Does anybody have an idea?


(Joe Fleming) #4

The generation URL isn't accessible that way, it has to use a POST request, not a GET request.

You'll also need to include a kbn-xsrf header in the request.

The documentation around using Reporting with Watcher outlines some of these things. It works with curl as well, you just need to include that header and make it a POST request.


(Daan) #5

Thank you @Joe_Fleming! That solved my problem.


(android.kc) #6

@DaanCreemers, can you please share your example of how to construct the POST request? thanks!


(android.kc) #7

it's actually quite simple and just worked. here is the header to include

"headers": {"kbn-xsrf": "reporting"}


(Daan) #8

@android.kc, yes, that's also how I did it.


(system) #12

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.