<< CSQL Cache Deployment Scenarios - TOC - Csql Datatype Mappings >>
For complete information about installing CSQL and its directory structure, Refer Section 3 in the CSQL User Manual. Download copy of CSQL package from http://www.csqldb.com
CSQL requires some system parameters that need to be set before starting CSQL database. These configuration variables are defined in a file called csql.conf. Some of the parameters mentioned in this file may have to be tweaked based on the requirements.
The lines starting with # are ignored as comments and the rest are treated as configuration variables. These variable values are read from this file during server start up.
These configuration variables are divided logically into following classes.
It is very important to note that for Server section parameters, the value should be the same for the server process and all the CSQL client processes, which connects to it. Otherwise, behavior is undefined. For Server and Client section variables, Refer Section 3.6.2.2 in CSQL User Manual.
The configuration file, csql.conf has nine parameters for caching. They can be found in cache section of the csql.conf file.
[CACHE_TABLE=true] This is a Boolean parameter and should be set to true in order to enable caching of tables from target database. Default value is false.
[SITE_ID=1] This is an integer parameter and it identifies a cache node instance in case of multiple cache nodes. If there is only single cache node instance, then set it to 1. For multi node caching, set this to a unique value for all the nodes. For example node instance-1 will have this parameter set to 1 and node instance-2 will have this parameter set to 2 and so on.
[DSN=myodbc3] This is set to data source name of target database and this data source name should present in the ~/odbc.ini file. The above DSN name (myodbc3) is for MySQL database, it could be changed for Postgres or Oracle or Sybase database based on the requirement. This is a string parameter.
[CACHE_MODE=SYNC] This is a string parameter, which takes values either SYNC or ASYNC. This determines the update propagation mode to target database for modification operations (insert, update and delete) on cached tables. Default value is SYNC.
[ENABLE_BIDIRECTIONAL_CACHE=true] This Boolean parameter is needed in order to enable “two way caching” (Bi-directional update propagation). Any updates on the target database will be applied to the cache and makes the cache coherent with the target database. Default value is false.
[CACHE_RECEIVER_WAIT_SECS=10] This is an integer parameter, which should be set to interval the server waits if there are no update logs from the target database in case of bi-directional caching. Default value is 10 seconds
[TABLE_CONFIG_FILE=/tmp/csql/csqltable.conf] This is a string parameter, which contains the complete path for csqltable.conf file, which holds the cache table information.
[DS_CONFIG_FILE=/tmp/csql/csqlds.conf] This is a string parameter, which contains the complete path for csqlds.conf file, which holds the information about data source name, user name, and password and target database name.
<< CSQL Cache Deployment Scenarios - TOC - Csql Datatype Mappings >>