Configuring a custom Visualization Platform client web application
Visualization Platform client’s configuration determines many of its essential methods. Configuring your web application customizes how it operates internally, and affects the user’s experience. Perform cosmetic customization tasks using the Visualization Platform client style sheets, as described in Modifying global style elements.
Set configuration parameters for the Visualization Platform client application to tune performance and to control service and application execution. For example, you can perform the following tasks using configuration parameters:
*Setting the default locale
*Controlling the Message Distribution service load balancing
Configure the Visualization Platform client application by changing configuration file contents, such as web.xml. The following section describes the customization procedure using the text editor.
How to customize Visualization Platform client configuration parameters
Use the following procedure to customize configuration parameters for Visualization Platform client. In this procedure, it is assumed that <context root>\WEB‑INF\web.xml is the configuration file.
1 Make a backup copy of web.xml.
2 Using a text editor that supports UTF‑8 encoding, edit web.xml to change parameter values. Parameter definitions use the following format:
<param-name><keyword></param-name>
<param-value><value></param-value>
*<keyword> is the name of the parameter.
*<value> is the parameter value.
Do not enclose the keyword and value within quotes, and use no spaces between <param-name>, the keyword or value, and </param-name>. For example, the definition for the default locale parameter is:
<param-name>DEFAULT_LOCALE</param-name>
<param-value>en_US</param-value>
3 Save web.xml.
4 Restart the application server or servlet engine that runs Visualization Platform client and clear your browser cache.
Setting the default locale
The default locale and time zone for Visualization Platform client are set when you install it. To change the default settings, you modify the values of the DEFAULT_LOCALE and DEFAULT_TIMEZONE configuration parameters.
How to set a default Visualization Platform client locale and time zone
1 Using a UTF-8 compliant code editor, open the web.xml configuration file.
2 Navigate to the lines that define DEFAULT_LOCALE, similar to the following code:
<param-name>DEFAULT_LOCALE</param-name>
<param-value>en_US</param-value>
Change the current locale id, en_US in the above example, to the desired locale id in param-value. Valid locale id strings are listed in <context root>\WEB‑INF\localemap.xml.
3 Navigate to the lines that define DEFAULT_TIMEZONE, similar to the following code:
<param-name>DEFAULT_TIMEZONE</param-name>
<param-value>America/Los_Angeles</param-value>
Change the current time zone id, Pacific Standard Time in the above example, to the desired default time-zone in param-value. Valid time zone id strings are listed in <context root>\WEB-INF\TimeZones.xml.
4 Save web.xml.
5 Restart the application server or servlet engine that runs Visualization Platform client and clear your browser cache.
6 Open the Visualization Platform client web application. The login page for the custom application appears.
Controlling the Message Distribution service load balancing
The default load balancing for Visualization Platform client are set to when you install it. To change the default settings, you modify the values of the MDS_ENABLED and MDS_REFRESH_FREQUENCY_SECONDS configuration parameters.
If you are using third-party load balancing, you will need to refer to their documentation to configure load balancing. See Understanding Visualization Platform clients.
How to enable the Message Distribution service
The Message Distribution service (MDS) is enabled by default. This procedure assumes it has been disabled.
1 Using a UTF-8 compliant code editor, open the web.xml configuration file.
2 Navigate to the lines that define MDS_ENABLED, similar to the following code:
<param-name>MDS_ENABLED</param-name>
<param-value>false</param-value>
Change the current value, if it is false, to true.
3 Navigate to the lines that define MDS_REFRESH_FREQUENCY_SECONDS, similar to the following code:
<param-name>MDS_REFRESH_FREQUENCY_SECONDS</param-name>
<param-value>0</param-value>
Change the current refresh frequency in seconds, 0 in the above example, to the desired number of seconds so that MDS will attempt to discover new nodes added to the cluster or remove nodes dropped from the cluster.
4 Save web.xml.
5 Restart the application server or servlet engine that runs Visualization Platform client and clear your browser cache.
Setting the JavaScript MIME types for Apache Tomcat
Apache Tomcat 6.0.39 or newer requires a text MIME type for the JavaScript mime-mapping configuration for Visualization Platform and iHub to support the Actuate JavaScript API.
How to change the mime-mapping configuration for Visualization Platform
1 Navigate to the following directory:
~\Actuate\iHub3\modules\BIRTiHub\iHub\web\iportal\WEB-INF
2 Open web.xml for editing and navigate to the mime-mapping section shown in Listing 2‑1:
Listing 2‑1 mime-mapping in web.xml for Visualization Platform
<mime-mapping>
<extension>js</extension>
<mime-type>application/javascript</mime-type>
</mime-mapping>
3 Change the value of the mime-type parameter to the following:
<mime-type>text/javascript</mime-type>
4 Save and close web.xml
5 Restart the Actuate iHub 3 Service
For more information about BIRT iHub Visualization Platform web.xml configuration, see Managing iHub Client Applications.