Configuring GBC client for applications

There are different methods for specifying the GBC client your applications use.

GBC client configuration

Table 1 describes how to configure the GBC client in the Genero Application Server (GAS) and specify a default.
Table 1. GAS configuration
Configuration File Description Usage
GBC_LOOKUP_PATH GAS configuration file (as.xcf) Add the path for your GBC directory, for example, <GBC_LOOKUP_PATH>c:/project_dir/dist/customization;…;$(res.fgldir)/web_utilities/gbc</GBC_LOOKUP_PATH> Required. If the client specified in GBC is not found in the path, the default client in the $(res.fgldir)/web_utilities/gbc is used.
Your default GBC client A file called _default Create a text file with the name "_default" in a root directory where you have GBC clients, for example, c:/project_dir/dist/customization/_default. The file contains the name or alias of a directory where the GBC client you want to set as default is found. Optional. _default is at a path found in the GBC_LOOKUP_PATH. Or if using the dispatcher override, _default is specified in the user path. Can be applied for a single application, or for all applications.
Tip: A GAS restart is not required when you update the _default file.

Applying GBC client

Table 2 summarizes two ways to specify the GBC client for a single application. Table 3 shows how to apply the GBC to use for all applications and override GAS defaults.
Table 2. Apply specific GBC client to use for an application
Applied to: Element/Option Description Usage
Your application configuration file (.xcf) GBC Specify the client to use in the GBC element, for example <GBC><my-gbc></GBC>, where my-gbc references either a directory name or _default file found in GBC_LOOKUP_PATH. See Specify in the application configuration file.
Application URL URL ?gbc query string parameter Specify the GBC client in the application URL, for example, http://myApplicationServer:6394/gas/ua/r/gwc-demo?gbc=<my-gbc> See Specify in the application URL.
Table 3. Apply GBC client for all applications launched by GAS
Applied to: Element/Option Description Usage
Dispatcher override -E res.path.gbc.user For example, start the standalone dispatcher with override, httpdispatch -E res.path.gbc.user=C:\my_gbc\1.00.40\dist\customization See Specifying default GBC client for applications.

Specify in the application URL

This method specifies the GBC client to use in the application URL.

Once you have deployed the GBC (using the gasadmin gbc command or the deployment portal), you can use the URL query string (?gbc=<my-gbc>) to specify which GBC client to use for the application when you run it:
http://myApplicationServer:6394/ua/r/gwc-demo?gbc=<my-gbc>

Specify in the application configuration file

This method uses the GBC_LOOKUP_PATH and GBC configuration parameters.

In the GAS configuration file, set GBC_LOOKUP_PATH to include the path to the folder that contains your customization directories.
Tip: The dispatcher searches the paths specified in order, therefore it is recommended to place the path to your GBC directory first in the path list.

In the application configuration file, set GBC to your GBC directory name.