Jump to content

Page not found after sucessfully running report using REST_V2 reportExecution service


rmorris

Recommended Posts

Hi everybody,

I'm using Jasper Server 7.1.0 Community Edition. I've recently started to try running reports asynchronously using the rest_v2 reportExecution service.

Right now I can successfully login via a GET or POST command, I can sucessfully run the report via a POST command, I can get the status the entire time it's running with no problem and I even successfully get the execution details when it's finished running... and it shows the correct number of pages, etc. too in the detail so I know it ran.

BUT... I simply CANNOT download the output afterward. Every time I try and issue a GET request using the request ID and export ID as instructed in the REST API documentation I always get a 404 "Page not found" error.

Can anyone please help? I have been at this for so long I don't remember when I started and I keep coming back to the same resources over and over and over when I search.

Thanks in advance!

 

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

I tested this in 7.1 Pro version and it worked for me. The main thing is to ensure you use the correct requestid and exportid that is generated after running the reportExecution POST request each time because a 404 signifies that the requestid or perhaps export id is not correct. Here is an example of the GET request to download :

http://server:8080/jasperserver-pro/rest_v2/reportExecutions/04c75230-dcb5-4833-9cb1-bebe416562cd/exports/de727d25-a45e-4019-bb36-a48177492780/outputResource

I also changed the header Content-Type to application/pdf for PDF output or text/html for HTML output.  

I use Postman tool to test. I haven't tested in Community version but I doubt the issue is due to that.  

Link to comment
Share on other sites

  • 1 year later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...