Factory Plugin Configuration File Overview
A factory plugin runs an Integrator script, which is written and tested separately, that can bring in additional columns for the factory to process into the output. The plugin can apply rules that the other factory rule types cannot run. The factory plugin configuration file (always called cfg.factory-plugin) is where you set up the plugin. To bring this additional information into the factory processing, a plugin tag is used within the data-set block of the factory configuration file.
The factory plugin configuration file has the following sections in the factory-plugin block:
- name—Provides a name for the plugin.
- description—Describes the purpose for the plugin.
- input—Sets the input for the plugin by indicating which columns to bring in with column sub-tags.
- integrator-script—Specifies the Integrator script to run.
- output—Sets the output for the plugin by indicating which dimensions and columns to create, using dimension and column sub-tags, that ultimately become part of the data set where the plugin-rule is called.
A simple factory plugin file is shown here:
Plugin files must be located in the factory project in the plugins directory (project://<project name>/plugins/<plugin name>/). For example:
The sample plugin is used in the cfg.factory file as shown here:
This example adds the Concat plugin to the Accounts data set and performs the following processing.
- Connects the Charges data set to the input of the plugin
- Specifies Account ID as the Key
- Specifies Revenue Description as the String
- Specifies that, to merge the plugin output back into Accounts, match the output Key with Account ID
- Calls the Concat result All Revenue Descriptions
See also:
- Factory Plugin Configuration File Code Block
- Factory Plugin Configuration File Tags
- Factory Plugin Rules
- Creating a Measure Factory Plugin
- Measure Factory Project Requirements