App Configuration

Configuration File Documentation

Configuration for App are defined in the config.toml (opens in a new tab) file.

1. Database Configuration:

The database section of this configuration file is used to specify the parameters for connecting to the database server. It provides the necessary information to establish a connection with the database where your application will store and retrieve data.

ParameterDescriptionSample Value
db_typeDatabase you want to connect (Supported : mysql, postgres, clickhouse)mysql
db_hostHostname or IP address of the database server.thinkbricks-db.ct00o317q97i.us-east-1.rds.amazonaws.com
db_portPort number for communication with the database server.3306
db_nameName of the database used to store application data.ecommerce_sample
db_userUsername for authenticating with the database server.admin
db_passwordPassword associated with the db_user account.password

2. Caching Configuration:

Caching is used to temporarily store frequently accessed data in a faster-accessible memory, reducing the need to fetch data from the database repeatedly.

ParameterDescriptionDefault Value
cache_enabledEnables or disables caching in the application.true
cache_expiryTime duration (in seconds) for cached data validity.3600 (1 hour)
cache_typeSpecifies the caching mechanism used (do not edit).memcached
cache_hostHostname or IP address of the caching server. (update it as per you server details)127.0.0.1 (local)
cache_portPort number for communication with the caching server. (do not edit - your cache server should be on this port)11211

3. Schema Parameters:

The schema section is related to the application's data schema and how it manages relationships between different database tables.

ParameterDescriptionDefault Value
fetch_schemaControls whether the application should fetch the schema information (you can set it to false once your schema file is generated and update is not required).true
relationship_filePath to the JSON file containing information about database table relationships (location of the file where your relationships are defined).data/relationships.json
schema_filePath to the JSON file containing table schema information for the database (do not edit, this file will be auto-generated).data/table_schema_db.json

Summary:

This configuration file is used to set up and configure the database connection, caching mechanism, and schema management for the application. By adjusting the values of the parameters, you can customize how your application interacts with the database and how caching is handled. Be cautious with sensitive information such as database passwords, and ensure that appropriate security measures are taken to protect this file from unauthorized access.