A connection configuration file is an XML file that specifies the data source connection properties to use when BIRT iHub runs a design. Having the data source connection information for a design in an external file makes it convenient to modify. You change the connection information without altering the design. You specify the location of the file in the template settings in acserverconfig.xml.
To specify the location of a data configuration file in acserverconfig.xml, add the ConnConfigFile property containing the configuration file path as shown in the following code:
<Config>
<Templates>
<Template ConnConfigFile="config_file_path">
....
</Template>
</Templates>
</Config>
You can create an external connection profile to a data source used by a design. Changes to the profile are automatically picked up by the design. The settings in a connection configuration file override any connection configuration properties in the connection profile. The sample connection configuration file in Listing 2‑7 externalizes the file path to the connection profile, C:\PostgreSQL.profile.
Listing 2‑7 BIRT connection configuration file example
In a BIRT design, the configuration key used to specify a data source is the unique ID of the ODA data source extension and data source name defined in the BIRT design or library. You must concatenate the string as follows:
extensionID + "_" + data source name
For example, the key is org.eclipse.birt.report.data.oda.jdbc_PostgreSQL.