1. Home
  2. FlexRule Server
  3. Installation
  4. Find your Configuration Files

Find your Configuration Files

Print Friendly, PDF & Email

◷ Reading Time: 5 minutes

When Configurator has finished the configuration it also creates your Agent and Master configuration file. FlexRule Server has a separate configuration file for each agent and master instance.

Config files

There are two types of configuration files:

  • Agent Configuration File: FlexRule.Server.ExecAgent.exe.config
  • Master Configuration File: FlexRule.Server.Master.exe.config

Adding configuration section

FlexRule Server has a custom configuration section that is enabled by ServerConfigFile.

<configSections>
  <section name="flexrule.server" type="FlexRule.Server.Configurations.ServerConfigFile, FlexRule.Server.Library" requirePermission="false" />
</configSections>

This then allows flexrule.server to be defined in the configuration files.

Agent config

<flexrule.server>
  <settings>
    <add key="AuthSigningKey" value="1234567890_1234567890_1234567890" />
    <add key="MasterAgentSharedSecret" value="this is a shared password between master and agents" />
  </settings>
 
  <agent>
    <add key="GenericLogger" value="FlexRule.Server.Logging.LogFileWriter, FlexRule.Server.Library" />
    <add key="ApiAddress" value="http://192.168.3.9:9002" />
    <add key="MasterAddress" value="http://192.168.3.9:9000" />
    <runtime>
      <add version="*" licenseFile="D:\Pliant Framework\FlexRule\5.4.2\Framework\flexrule.license.lic" />
    </runtime>
  </agent>
</flexrule.server>

settings

  • AuthSigningKey: This is the same key that the Master uses to sign the authentication token.
  • MasterAgentSharedSecret: This is the same key that Master and Agent share to identify each other.

agent

  • ApiAddress: address that the agent will listen to in order to receive requests from its Master server.
  • MasterAddress: the agent’s master server address
runtime

Agent requires the FlexRule Runtime to be installed (which the installer does automatically), but for running the agent and executing logic, it must have the license for FlexRule Runtime. In the runtime section, based on a particular version you can set the path to the license.

  • version: default is * which means any version; otherwise the specific version number.
  • runtime: reference to the license file for FlexRule runtime that allows the Agent to execute logic

Master config

<flexrule.server>
  <settings>
    <add key="MasterEncryptionPassword" value="1234567890" />
    <add key="AuthSigningKey" value="1234567890_1234567890_1234567890" />
    <add key="MasterAgentSharedSecret" value="this is a shared password between master and agents" />
  </settings>
 
  <master>
    <add key="GenericLogger" value="FlexRule.Server.Logging.LogFileWriter, FlexRule.Server.Library" />
    <add key="DbAddress" value="D:\Pliant Framework\Server\Master\databases" />
    <add key="ApiAddress" value="http://192.168.3.9:9000" /> 
    <add key="WorkbenchAddress" value="http://192.168.3.9:9003" />
    <add key="WorkbenchPath" value="..\Workbench\home" />
    <!-- Remove the runtime section below to disable executing logic on Master node -->
    <runtime>
      <add version="*" licenseFile="D:\Pliant Framework\FlexRule\5.4.2\Framework\flexrule.license.lic" />
    </runtime>
  </master>
</flexrule.server>

settings

  • MasterEncryptionPassword: This password is used to encrypt User and Application account information (e.g., password) when they are stored in the database
  • AuthSigningKey: This is the same key that the Agent uses to sign the authentication token.
  • MasterAgentSharedSecret: This is the same key that the Master and Agent share to identify each other.

master

  • DbAddress: Database connection string or path address to the database file.
  • ApiAddress: address that the Master will listen to in order to receive requests from any client in its public API interface.
  • WorkbenchAddress: the Workbench web application address
  • WorkbenchPath: the Workbench web application physical path to its folder.
runtime

Master can be responsible for executing logic on the Master Node, so it needs to have the FlexRule Runtime installed (which the installer does automatically). However, for running the agent and executing logic, it must have the license for FlexRule Runtime. In the runtime section, based on different versions, you can set the path to the license.

  • version: default is * which means any version; otherwise the specific version number.
  • runtime: reference to the license file for FlexRule runtime that allows the Agent to execute logic

It’s better to disable execution on the Master node and just dedicate the Master for management only. This frees up resources on the Master node and lets it dispatch requests to Agents faster. To disable execution on the Master node, just remove the <runtime> section from the Master config file.

Workbench

To configure your Workbench you need to edit the Workbench configuration file. Workbench has a configuration file under:

[Local Disk]/Program Files (x86)/Pliant Framework/FlexRule Server/<version>/Master/Workbench/FlexRule/Config.jsx

Open the file by using any text editors (e.g., Notepad), then you will be able to change the the masterAddress. During the installation, the default Address is “localhost:.

masterAddress: 'http://localhost:9000'

Monitoring section

<monitoring>
  <add event="ExceptionTraceEvent" channel="eventLogListener" level="Error" enable="true" includeDetails="true" prettifyDetails="true"/>
  <add event="ExceptionTraceEvent" channel="fileLogListener" level="Error" enable="true" includeDetails="true" prettifyDetails="true"/>
 
  <channels>
    <add initializeData="D:\Pliant Framework\Server\Agent\agent.log" type="System.Diagnostics.TextWriterTraceListener, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" name="fileLogListener" />
    <add initializeData="" type="System.Diagnostics.EventLogTraceListener, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" name="eventLogListener" />
  </channels> 
</monitoring>
Updated on August 8, 2019

Was this article helpful?

Related Articles