Import and Export Through the Web UI

JasperReports Server provides functionality to import and export resources and users through the user interface:

Exporting From the Repository
Exporting From the Settings
Importing From the Settings

When importing and exporting through the web interface, remember the following:

If you're importing to a different server, you must configure an encryption key on both servers, as described in Setting the Import-Export Encryption Key. You'll need to enter the keystore password when prompted by the import operation.
Make sure the output location specified for an export is writable for the local user running the app server containing JasperReports Server.

Exporting From the Repository

To export individual resources or an entire folder of the repository:

1. Log in as system administrator (superuser by default).
2. Select View > Repository. You can also export reports, Ad Hoc views, dashboards, and OLAP views from the Library page.
3. Select one or more resources in the main panel, or when viewing the repository, select a folder in the left-panel.
4. Right-click the selected folder or resources and select Export from the context menu. The Export Resources dialog appears:

Export Resources Dialog in the Repository

5. Name of the zip file for the exported catalog. The dialog supports only the zip archive format.
6. Choose one or both of the include options:
     Include repository permissions Enabled by default. Clear this checkbox if you want the exported items to inherit the permissions of the destination repository.
     Include report jobs Select if you want to include scheduled report jobs with any reports included in the selection.
7. Click Export. The server generates the catalog zip file and your browser prompts you to save the file. Depending on the size of your repository and the options you’ve selected, it may take several minutes to generate the catalog file.

Resources are exported along with any dependencies, even if they're not located in the selected folders. For more information, see Import and Export Catalogs.

Exporting From the Settings

To export users and roles in addition to, or instead of, repository contents, use the server settings page for system administrators. This page offers more options than the contextual export from the repository.

As of JasperReports Server 5.5, all exports contain encrypted passwords and if you're importing to a different server, you must configure an encryption key on both servers. See Setting the Import-Export Encryption Key for details.

To export data from the settings:

1. Log in as system administrator (superuser by default).
2. Select Manage > Server Settings, then click Export in the left-panel.

User Interface for Export

3. Specify the name of the zip file for the exported catalog. The web UI supports only the zip archive format.
4. Use the cascading input controls to choose the contents of your exported catalog file:
a. Select Export Everything (default) to export the entire repository, including permissions report jobs, all organizations, users, and roles. Check the box for Include access events if you want to include resource modification times.
b. Clear Export Everything to select only users and roles to export. Then choose one of the User and Role Selection options. You can directly select users and roles to export or select them indirectly. For example, if you choose Export users with selected roles, you'll select users; and the server will export them with their assigned roles.
5. To select specific users and roles:
a. Select Export individually selected roles and users.

The Select users and Select roles lists become active.

b. Select the users and roles to export.
6. To select roles:
a. Select Export users with selected roles.
b. Select the roles to export. The server will also export the users that are assigned those roles.

The users assigned the roles you selected are highlighted.

7. To select users:
a. Select Export roles assigned to selected users.
b. Select the users to export. Their roles will also be exported.

The roles assigned the users you selected are highlighted.

8. In commercial editions of JasperReports Server, you can check Include audit events and Include monitoring events as needed.
9. Click Export. The server generates the catalog zip file and your browser prompts you to save the file. Depending on the size of your repository and the options you’ve selected, it may take several minutes to generate the catalog file.

Importing From the Settings

The Settings pages for system administrators include a user interface to simplify the import procedure.

This import operates on a running instance of the server, and all imported resources are visible immediately. In addition, any configuration or security settings in the imported catalog take effect immediately, with no need to restart the server.

As of JasperReports Server 5.5, all exports contain encrypted passwords and if you are importing to a different server, you must configure an encryption key on both servers. See Setting the Import-Export Encryption Key for details.

You cannot use the import UI to import a catalog from a JasperReports Server 5.2 or earlier if it was created with the "export everything" option. Theme files contained in export catalogs from previous versions of the server will overwrite newer themes, but they are not compatible and cause HTML display errors. To import a catalog from a previous version of the server, use the command line utility <js-install>/buildomatic/js-import.bat or .sh with the --skip-themes option.

If you have a custom theme to import, you can use the Theme UI to download it from the source server and upload it to the target server. If your theme contains the file pageSpecific.css, you must remove it from the ZIP file before uploading, and then redo your changes to the file based on pageSpecific.css in the target server from 5.5 or later. For more information, see Downloading and Uploading Theme ZIP Files.

To import data from the settings:

1. Log in as system administrator (superuser by default).
2. Select Manage > Server Settings and choose Import in the left-hand panel.

User Interface for Import

3. Click Browse to choose the catalog zip file to import. The web UI supports only the zip archive format. You can import any catalog zip file created by the export UI or the command-line export utility.
4. Use the check boxes to change the behavior of the import operation:
     When checked, the Update option will import only resources that are newer than ones with the same URI in the current repository. The Skip user updates option allows you to keep the current definition of any users that also exist in the imported catalog.
     When checked, the Include access events option imports the modification times of resources from the catalog. When cleared, resources keep their existing access times if they already exist.
     In commercial editions of JasperReports Library, the Include audit events and Include monitoring events determine whether access and monitoring events from the catalog, if any, are imported.
     The Include server settings option determines whether the system configuration is updated from the catalog. There are two pre-requisites in order for the catalog to contain configuration settings:
The originating server settings must be modified through the UI. Thus, only Log Settings, Ad Hoc Settings, AWS Settings, and OLAP Settings are affected. For more information, see Configuration Settings in the User Interface
The catalog must be exported with the “everything” option from the user interface or the command-line utility.

When server settings are imported, they take effect immediately and appear in the Settings UI.

5. Click Import.

The server uploads the catalog zip file and imports its contents into the repository. Depending on the size of the catalog and the options you’ve selected, it may take several minutes to perform the import.

Version: 
Feedback
randomness