DataSource.NET  7.1.29.112283-2b6ad187
Configuration

Configuration

Introduction

DataSource.NET is configured using structured plain text configuration files (.conf files) that have the same format as the configuration files used by the Caplin Liberator. For more detailed information on configuring DataSource applications using .conf files, refer to the relevant sections of the Liberator Administration Guide, in particular the sections on configuring DataSource peers, Data Services, and fields.

Configuring DataSource Connections

DataSource.NET must be configured in order to know which peers (for example, Liberator or Transformer) to connect to, or alternatively, to accept connections from. Generally DataSources that supply data will connect to a DataSource that consumes their updates.

Peer connections can be configured using the add-peer configuration group. For example, to configure DataSource.NET to connect to a DataSource peer running on server1 accepting DataSource connections on port 25000, use the following configuration:

   add-peer
    addr    server1
    port    25000
    local-id 1
   end-peer
   

Alternatively, the connection direction can be reversed, and a DataSource peer can connect to a DataSource.NET application. The following example shows DataSource.NET listening on port 25000 for connections from a peer on any host which has a id of 1:

   datasrc-port 25000
   add-peer
    local-id    1
    remote-id   2
   end-peer
   

Configuring Fields

A set of fields makes up a data object or an update to an object. Standard record objects consist of fields, whereas other data types may store data in a different way.

Fields are defined in the .conf configuration file (or in a file that is included in the configuration file) using the add-field configuration item. The simplest form of add-field takes two arguments as follows:

add-field  FieldName FieldNumber

Where FieldName is the name of the field and FieldNumber is a unique number that this FieldName maps to. For example, the following configuration maps the field name "bid" to the field number 1033:

add-field  bid 1033

The same field number must be given the same meaning in all communicating DataSource applications, though the actual name mapped can be different. Thus, for example, a Liberator that is supplied with "bid" information from your DataSource.NET application, could map field 1033 to the "Bid" (with a capital 'B').


Generated on Wed Mar 8 2023 19:11:38 for DataSource.NET