Switching your ReportServer archive tables off

ReportServer uses Hibernate Envers (https://hibernate.org/orm/envers/) as an archiving / versioning solution for entity classes. This might result in an unexpected and unwanted growth of size of the ReportServer repository database.

A new revision is created on every single entity change, so the archive tables grow with each entity modification. Thus, these tables get larger and larger, making your DB occupy a large amount of space after some time. If you don’t need the archive tables, you can easily turn this behaviour off.

For each table in the ReportServer repository there is a shadow table which has the same as the original tables plus the suffix _A. All entity versions can be found in the these tables. The “_A” suffix stands for “archive” or “audit”. So, e.g., your User’s revisions are found in the RS_USER_A archive table, since the respective actual entity versions are located in the RS_USER table.

To stop this behaviour in your ReportServer installation, open your persistence.xml and locate the section containing the string <!– Envers –>.
Then add the following:

<property name="hibernate.integration.envers.enabled" value="false"/>

The result would be similar to:

<!-- Envers -->
<property name="org.hibernate.envers.audit_table_suffix" value="_A"/>
<property name="org.hibernate.envers.audit_table_prefix" value=""/>
<property name="hibernate.integration.envers.enabled" value="false"/>

After a ReportServer restart, you can make sure that the archive tables are switched off by opening a ReportServer terminal session and typing a rev command for a given entity, as in this example:

Making sure the archive tables are switched off

If you get the message “Service is not yet initialized”, the archive tables are correctly turned off.

Once your archive tables are switched off, you can modify your “_A” tables: you can either leave them as they are or delete the entries.

Attention:
Once the archive tables are switched off, they cannot be switched on again unproblematically.
Pls. do not confuse the archive tables with the audit log ReportServer maintains in the RS_AUDIT_* tables. These are not impacted by the operations described above.

ReportServer 3.1.1

The 3.1.1 version is now available for all users.
In the following some important features in this version:

Allow to change lost password email texts via config file

ReportServer 3.1.1 allows you to edit the text a user receives per email when the user’s password is lost. The following is a configuration file for this purpose (/etc/security/lostpassword.cf)

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
      <lostpassword>
         <email>
            <subject>Password lost</subject>
            <text>Dear user ${user.getFirstname()} ${user.getLastname()},

A password request was issued for:

   User: ${user.getUsername()}
   Password: ${password}
	    </text>
         </email>
      </lostpassword>
</configuration>

Add “config echo” command for printing out individual current configuration parameters

In order to read the current active value of a configuration parameter, you can use “config echo”, e.g. for reading the default charset in the main.cf configuration file:

config echo main/main.cf default.charset

would return you e.g. “UTF-8”. For reading an attribute in the form:

<mailaction html="false">

you can write:

config echo scheduler/scheduler.cf scheduler.mailaction[@html]

More details on the syntax can be found in the Apache Commons Configuration documentation

Allow to configure the width of the columns in the dynamic list preview

You can now set the column widths of your dynamic lists via dynamic list configuration, refer to the next screenshot for an example.

You can also set defaults for all dynamic lists in the “/etc/ui/previews.cf” configuration file (defaultColumnWidth, maxColumnWidth):

<?xml version="1.0" encoding="UTF-8"?>
<!--
 ReportServer Configuration File
 filename: ui/previews.cf

 Configures how previews are rendered
-->
<configuration>
   <pdf>
      <mode>native</mode>
   </pdf>
   <dynamicList>
      <defaultColumnWidth>200</defaultColumnWidth>
      <maxColumnWidth>800</maxColumnWidth>
   </dynamicList>
</configuration>

Allow to configure if user account existence should be shown in the lost password dialog

You can now configure if the lost password dialog should reveal if the given username is existent or if no information should be disclosed. Per default, no information is disclosed. The configuration setting (indicateWrongUsername) is found in the /etc/security/lostpassword.cf file:

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
      <lostpassword indicateWrongUsername="false">
         <email>
            <subject>${msgs['net.datenwerke.rs.passwordpolicy.service.locale.PasswordPolicyMessages']['lostPasswordSubject']}</subject>
            <text>${msgs['net.datenwerke.rs.passwordpolicy.service.locale.PasswordPolicyMessages']['lostPasswordSalutation']} ${user.getFirstname()} ${user.getLastname()},

${msgs['net.datenwerke.rs.passwordpolicy.service.locale.PasswordPolicyMessages']['lostPasswordIntro']}

   ${msgs['net.datenwerke.rs.passwordpolicy.service.locale.PasswordPolicyMessages']['lostPasswordUsername']}: ${user.getUsername()}
   ${msgs['net.datenwerke.rs.passwordpolicy.service.locale.PasswordPolicyMessages']['lostPasswordPassword']}: ${password}

${msgs['net.datenwerke.rs.passwordpolicy.service.locale.PasswordPolicyMessages']['lostPasswordEnd']}

	    </text>
         </email>
      </lostpassword>
</configuration>

Library Deletions and Upgrades

In ReportServer 3.1.1 we deleted 52 libraries and upgraded 8. This removes many external dependencies in ReportServer.

For a list of all changes please refer to the release notes. The upgrade guide is available in the documentation area.
Happy reporting!