Resource

JReport Enterprise Server provides a resource system for managing a group of archive versions that can be processed or organized.

What is a resource

Generally, a resource refers to report set related material. To be exact, a resource in the JReport Enterprise Server reporting system is a conceptual node. There are different types of resources, such as catalogs, report sets, and report set results. A resource can only hold versions of the same type.

Resource tree

All the resources are organized in a folder-tree structure. JReport Enterprise Server defines an XML file called admin.xml, and the resource tree conforms to this file. This file is maintained automatically by JReport Enterprise Server.

For example, your company has two departments - Support and Marketing. Each department has its report sets on their own machine. There are some report set documents that are submitted by the departments located on the machine where JReport Enterprise Server runs. Now, suppose you are the administrator, and you would like to organize these files and folders into the Resource Tree. The following diagram may help you to figure out the framework on which you should build the resource tree.

The resource tree consists of three layers: Folder layer, Resource layer, and Archive layer.

Folder layer: Basic resource tree element that builds the main framework for the resource tree. There are two built-in folders in the root of the resource tree -- Public Reports and My Reports. A folder can be mapped to a real file path.

Resource layer: An abstract layer, based on the Folder layer that hosts various types of archive versions and provides user access to the versions.

Archive layer: A concrete layer, where the archive versions reside for executable report sets, report catalogs, and report set results, which function as the leaves of the resource tree.

Public Reports and My Reports

There are two built-in folders in the resource tree root - Public Reports and My Reports. You can create your own folders in either of them. The Public Reports folder and the My Reports folder cannot be deleted.

The Public Reports folder contains public report set documents and executable report sets, and can be accessed by everyone. All folders except for the personal folders are public folders.

The My Reports folder is a personal folder. It contains personal report set documents and executable report sets. Each user has one personal folder, specified by the administrator when the user account is created. The My Reports folder can only be accessed by its owner, and the user has full control over his/her personal folder. This folder is the default output location for report sets run by the user.

Report set

A report set is a collection of reports. All reports in one report set may share the same query, dataset, parameters, NLS and style group properties. Generally, reports in one report set are designed for the same purpose, or for related purposes. JReport Enterprise Server supports viewing, running, scheduling and managing of report sets.

An additional advantage of report sets is that all reports and subreports can share the same dataset which means that only one query to the DBMS is required to run the reports and all of the subreports. From a performance perspective, this is very important because if each subreport is a report set, then each subreport will retrieve the data from the DBMS even though it may be identical to the main report and other subreports.

The result version and the background run/scheduled/active/completed record are based on report set level.

When viewing a report set directly, if DHTML is set as the default report view format, the report set with all its reports will be run. Otherwise, only the default selected report will be run.

When using Advanced Run to run a report set, you can only select one report in the report set to run.

When using scheduling to publish a report set to the versioning system or to disk, the DHTML and JReport Result formats are based on the report set level, that is, the report set with all selected reports will be output to a single file. As for the other formats, each selected report will be output to a separate file but you still have the convenience of scheduling all the reports with a single schedule entry.

Related topics: