For our Project we are developing a web app consisting of a TypeScript Frontend and Java Backend. In this app, the user has the option to request a report. The report is generated by Jasper Server v7. To get access to the required data, we have added a JSON-DataSource to the Jasper Server, which uses the REST-API of our Java Backend. When we call the Jasper Server, we use a few request parameters, which in turn are also used for the JSON-DataSource.
To create the DataSource, we have to use default-parameters for the request parameters. If we just keep the fields empty, it just throws an error and doesn't let us continue.
Our problem is, whenever we request a report now, our backend is called two times, first with the default parameters we used when we set up the report, an then with the parameters we send to request the report. Is there any way to prevent the first "default" call? Everything is functioning correctly, but the unnecessary request just creates more load on our server, which we want to reduce.
Our JasperSoft Studio Version is 6.12.2 (we use this version on purpose, since the newer versions lead to other problems).
Hello, we got the same problem 3 or 4 years ago and we had to found a workaround for that.
We added a parameter called "ping" with "true" as default value
It seems the defaut values of the parameters are used in that stange first call.
In the backend, if "ping"is "true", we return a success and no value.
Then, we call the data forcing "ping" to false to get the real values
This is very strange, it seems this first call is a "hey, do you live ?" called via the /inputcontrol url. That's why we called that dummy parameter "ping"
I hope it will help