View source | Discuss this page | Page history | Printable version   
Main Page
Upload file
What links here
Recent changes

PDF Books
Add page
Show collection (0 pages)
Collections help


Reporting Server/Server Configuration


The Openbravo Reports Server is implemented using Jaspersoft Reports Server. This document describes the configuration of the Openbravo Reports Server, both for the database as well as for configuration of the Jasper Reports Server itself.

Note: that for our customers we will deploy a server using a standard pre-build instance. This document describes the steps from this basis configuration. The first section below describes what is included in this pre-build instance.

Pre-build instance contents

This document assumes a reporting server instance provided by Openbravo and it describes the configuration/customization steps from this basis. This document then assumes that you have a server with the following installed:

Main Configuration Steps

Build environment: add your custom modules and do install.source

Your reports server will contain custom domains and reports which are delivered through modules. See for example the Sales Reports modules.

To make use of these modules do the following:

Configure single sign on - automatic login

Copy the file modules/ to


Generate a printable character random string of length 16 and place it in the top of the file, remove the comments in the file so only the random string remains.

For example:

sudo apt install pwgen
pwgen 16 > jasper-config/

Note: a key of length 32 will be supported in later releases.


Then go to the modules/ module folder and copy to


Set the reporting properties. There are different sections each is described separately within the property file, the following needs to be set for the configuration:

The following information is used later in the dataload step. It makes sense to already set them right away:

Set webservice connection information

Note: this section is mostly relevant if you are installing from an Openbravo instance without running the Openbravo UI. If there is a UI, the information in this section can also be set by logging into the backoffice and creating a reporting configuration record.

The system needs webservice connection information to upload the reports from the modules into the reporting server. This webservice connection information is set using the following ant command (from/in the module folder):

ant create.update.reporting.config -Dpassword=[PWD] -Durl=https://[HOST]/jasperserver-pro

Note: if the password has non-alphabetic characters then the system might show an error. In that case you can try to enclose the password value with double quotes "".

Replace the placeholders ([PWD] and [HOST]) with your corresponding information. By default the system will use the superuser for uploading the modules, if you want to choose a different user, then pass also the 'user' parameter.

Create the reporting database

To create the reporting database perform the following ant action from/in the module folder:

ant create.reporting.database

Update the system configuration files and restart tomcat

We use specific settings for the database connection, single sign on and templates. To copy/overwrite the relevant configuration files in the jasper webapp do the following ant action from within module folder:

ant setup.jasper.for.openbravo

This action assumes that jasper is installed in /var/lib/tomcat/webapps/jasperserver-pro. If in your case jasper is installed in another location use the parameter (pass it as[PATH_TO_JASPER_WEBAPP] in the above ant task).

Restart the reports server webapp:

sudo /etc/init.d/tomcat restart

Upload the System setup to the reports server repository

Make sure the jasper server is running and that the webservice properties are set in the file.

Then perform the following ant action from/in the module folder:


Upload custom reports and other modules data into the reports server repository

Normally you should have modules providing reports, ad-hoc views and domains. For each of these modules you need to execute the upload step to upload the reports to the reports server repository.

Note: the upload step should be done in the order of the dependencies of the modules.

For example, to upload the reports provided by the reporting sales module do the following:


Generate and configure the data loader application

Generate the data loader application

The reports server setup is complete now the next step is to enable data loading. The first step is to generate the data loader application itself. Execute the following ant action in the modules/ module:

ant generate.dataloader.application -DtargetDir=/opt/OpenbravoReporting/DataLoaderApp

This will generate the data loader app in the /opt/OpenbravoReporting/DataLoaderApp folder. Note: this assumes that the linux user can create that folder if it does not already exist.

Check data loader log4j2.xml

In the target data loader folder you will find a log4j2.xml file. Check if it has the appropriate settings for your logging requirements.

Add a cron job to load the data periodically

There is a sample update script in the dataloader application (update_script). Check its content and make sure the cd command in it points to the correct install location.

Set the update script file (located in the target directory) to executable:

chmod +x update_script

Then enable the load through the cron by doing crontab -e. Note that some additional settings are needed to make sure that ant runs correctly from cron:

05 */3 * * * /opt/OpenbravoReporting/DataLoaderApp/update_script

Note: this is just an example setup for cron. Choose the setup/timing needed for your specific case.

Post configuration steps

After configuring the system itself there are several steps remaining:

Jasper user role pull down.png

The Jasper Administrator guide provides more details on these steps.

Other configurations

Email configuration & Report Scheduling

Openbravo does not provide a SMTP server, to set your own SMTP information in the WEB-INF/ file:[SMTP-HOST]
report.scheduler.mail.sender.from=[FROM EMAIL]
report.scheduler.mail.sender.protocol=[smtp or smtps]
report.scheduler.mail.sender.port=[PORT, eg. 465]

Check that the url is correctly set in the WEB-INF/ file:


In the file WEB-INF/applicationContext-report-scheduling.xml add the mail.smtps.auth tag:

        <property name="javaMailProperties">
                <prop key="mail.smtp.sendpartial">true</prop>
                <prop key="mail.smtps.auth">true</prop>

Do the same in WEB-INF/applicationContext.xml.

Enable view query in ad-hoc views

Within ad-hoc views there is a button to view the underlying sql query. This button is not enabled by default. This link describes how to enable it.

Retrieved from ""

This page has been accessed 3,035 times. This page was last modified on 21 March 2020, at 10:13. Content is available under Creative Commons Attribution-ShareAlike 2.5 Spain License.