Jump to content
Changes to the Jaspersoft community edition download ×

Upload new jrxml file via REST API


valeriya0606

Recommended Posts

Hello. I would like to use REST API for Jasperreports server. I have there already created reportunits. Now I made some changes to jrxml files and wants to upload them via REST API.

When I use POST method, new reportunit with new jrxml file is created. If I use PUT with "overwrite?=true" than my existing reportunit is completely overwritten. But, it's not suitable for me as I need to have all images and inputControl files left intouched. I would use PATCH method, but it seems not be supported by Jasperreports anymore. Any advice if my main goal is possible to achieve? To sum up, I need to update only one jrxml file, nothing else. 

 

Link to comment
Share on other sites

  • 3 weeks later...
  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Don't mess with the descriptor.  Just upload the new JRXML file using the resources API to the files directory:

    /public/Samples/Reports/<some report uri>_files/

Or upload your JRXML files separately then reference them in your report descriptors instead of storing local.  This way you can simply replace the referenced JRXML file.

Link to comment
Share on other sites

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...