After [[Invantive UniversalSQL Server/Configuration/Installation|Installation]], Invantive UniversalSQL Server is configured through an `appsettings.json` file. The application-specific part of the configuration file is shown below. In demo and local mode, a local [[Settings.xml]] file will be used to define the available database. In Invantive Cloud mode, the Invantive Cloud databases available to the Invantive Cloud user will be available. The product can be configured further through [[Environment Variables]]. ## Examples The following JSON is an example, with standardized configuration component contents replaced by "...": ```json { ... , "Server": { // // ID. // , "Id": "acme-server" // // Description. // , "Description": "Settings for Invantive UniversalSQL Server", // // Name of the node. // , "NodeName": "XYZ1234" // // Server host name. // , "HostName": "ws238" // // Listen IP address (use "*" to listen on all IP-addresses). // , "TdsListenIpAddress": "*" // // Listen port. // , "TdsListenIpPort": 1433 // // Whether the monitor is active. // , "IsMonitorActive": true // // Monitor IP address (use "*" to listen on all IP-addresses). // , "MonitorListenIpAddress": "*" // // Monitor IP port. // , "MonitorListenIpPort": 5933 // // SSL certificate file name/path. // , "SslCertificateFileNamePath": "/mnt/certificates/database.acme.eu/acme_eu.pfx" // // File name and path to store dump with public elements of certificate. // Intermediate and root certificates are stored in the same path. // // Starting release: 26.0.70 // , "SslCertificateDumpPemFileNamePath": "/tmp/acme_eu.pem" // // SSL certificate password. // , "SslCertificatePassword": "secret" // // Folder to use for HTTP disk cache for the current user. // , "UserHttpDiskCacheRootDirectory": "/mnt/database/cache/cache" // // Folder to use for HTTP disk cache for publicly available data. // , "PublicHttpDiskCacheRootDirectory": "/mnt/database/cache/public" // // Incremental data root directory. // , "IncDataCacheRootDirectory": "/mnt/database/cache/incdata" // // Permanent cache root directory. // , "PermanentDataCacheRootDirectory": "/mnt/cache/permanent" // // Maximum age in seconds to allow use data from disk cache. // , "RetrieveFromDiskCacheMaxAgeSec": 57600 // // Maximum age in seconds to allow use data from memory cache. // , "RetrieveFromHttpMemoryCacheMaxAgeSec": 57600 // // Maximum age in seconds to allow storage of data in disk cache. // , "StoreAnswerInDiskCacheMaxAgeSec": 57600 // // Whether to store data in disk cache. // , "StoreInHttpMemoryCache": true // // Whether to store data in memory cache. // , "StoreInDiskCache": true // // Trace and logging options. // , "TdsTrace": ... // // Host name to database name postfix. // , "HostNameToDatabasePostfix": ".database.acme.eu" // // There are three possible modes to run Invantive UniversalSQL Server in: // // * Demo mode: set IsDemoMode to true. // * Cloud-integrated: set IsCloudMode to true. // * Local: set IsDemoMode to false and IsCloudMode to false. // // Whether to run in demo mode. // , "IsDemoMode": false // // Demo configuration. // , "Demo": ... // // Whether to run in Invantive Cloud mode. // , "IsCloudMode": false // // Invantive Cloud API configuration. // , "CloudApi": ... // // Configuration independent from Invantive Cloud. // , "Local": ... // // Monitor server users. // , "MonitorUsers": ... // // Elastic APM // , "ElasticApm": ... } } ``` ## Definition References are made to configuration components standardized across all Invantive technology web applications, although not all configuration components must have been implemented in all web applications: - [[Demo Configuration]] - [[Invantive Cloud Connection Configuration]] - [[Local Configuration]] - [[Query Rewrite Rules Configuration]] - [[Server Mode Configuration]] - [[TDS Trace Configuration]] - [[Users Configuration|Users Configuration]] - [[Server Modes]] - [[Elastic APM Configuration]] - [[Application Setting Components/Monitoring Configuration]] ```json { "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "ServerConfig.schema.json", "title": "ServerConfig", "description": "Invantive UniversalSQL Server master configuration.", "type": "object", "additionalProperties": false, "properties": { "Id": { "type": [ "string", "null" ], "description": "The ID." }, "Description": { "type": [ "string", "null" ], "description": "The description." }, "NodeName": { "type": [ "string", "null" ], "description": "The node name." }, "HostName": { "type": [ "string", "null" ], "description": "The host name." }, "TdsListenIpAddress": { "type": [ "string", "null" ], "description": "The listen IP address for the server with the TDS-protocol (use \"*\" to listen to all IP-addresses)." }, "TdsListenIpPort": { "type": [ "integer", "null" ], "description": "The listen port for the server with the TDS-protocol." }, "MonitorListenIpPort": { "type": [ "integer", "null" ], "description": "The listen port for the interactive monitor." }, "MonitorListenIpAddress": { "type": [ "string", "null" ], "description": "The listen IP address for the interactive monitor (use \"*\" to listen to all IP-addresses)." }, "SslCertificateFileNamePath": { "type": [ "string", "null" ], "description": "The SSL certificate file name path." }, "SslCertificatePassword": { "type": [ "string", "null" ], "description": "The SSL certificate password." }, "ConnectTimeoutSec": { "type": [ "integer", "null" ], "description": "The timeout for connection establishment in seconds." }, "ReceiveTimeoutSec": { "type": [ "integer", "null" ], "description": "The timeout for receive data in seconds." }, "SendTimeoutSec": { "type": [ "integer", "null" ], "description": "The timeout for send data in seconds." }, "PacketSize": { "type": [ "integer", "null" ], "description": "The packet size in bytes." }, "SocketQueueSize": { "type": [ "integer", "null" ], "description": "The socket queue size in bytes." }, "UserHttpDiskCacheRootDirectory": { "type": [ "string", "null" ], "description": "Root directory containing the HTTP disk cache files for the current user." }, "PublicHttpDiskCacheRootDirectory": { "type": [ "string", "null" ], "description": "Root directory containing the HTTP disk cache files for publicly available data (shared between users)." }, "IncDataCacheRootDirectory": { "type": [ "string", "null" ], "description": "Root directory containing the incremental data cache files." }, "PermanentDataCacheRootDirectory": { "type": [ "string", "null" ], "description": "Root directory containing the permanent data cache files." }, "RetrieveFromDiskCacheMaxAgeSec": { "type": [ "integer", "null" ], "description": "Maximum age in seconds to allow use of data from disk cache." }, "RetrieveFromHttpMemoryCacheMaxAgeSec": { "type": [ "integer", "null" ], "description": "Maximum age in seconds to allow use of data from memory cache." }, "StoreAnswerInDiskCacheMaxAgeSec": { "type": [ "integer", "null" ], "description": "Maximum age in seconds to allow storage of data in disk cache." }, "RetrieveFromDiskCache": { "type": "boolean", "default": false, "description": "Whether to use data from disk cache." }, "RetrieveFromHttpMemoryCache": { "type": "boolean", "default": false, "description": "Whether to use data from memory cache." }, "StoreInDiskCache": { "type": "boolean", "default": false, "description": "Whether to store data in disk cache." }, "StoreInHttpMemoryCache": { "type": "boolean", "default": false, "description": "Whether to store data in memory cache." }, "HostNameToDatabasePostfix": { "type": [ "string", "null" ], "description": "The host name to database name postfix." }, "ScriptingFolderPath": { "type": [ "string", "null" ], "description": "The scripting folder path." }, "IsCloudMode": { "type": "boolean", "default": false, "description": "Whether running as an Invantive shared Cloud service, such as Invantive Cloud." }, "IsDemoMode": { "type": "boolean", "default": false, "description": "Whether to run in demo mode." }, "IsSharedEnvironment": { "type": "boolean", "description": "Whether the Invantive UniversalSQL Server environment is an environment shared by multiple companies.", "readOnly": true }, "IsMonitorActive": { "type": "boolean", "default": false, "description": "Gets whether the monitor is active." }, "TdsTrace": { "$ref": "TdsTraceConfig.schema.json", "description": "TDS trace options." }, "QueryRewriteRules": { "anyOf": [ { "$ref": "QueryRewriteRules.schema.json" }, { "type": "null" } ], "description": "Rules to rewrite SQL statements received to Invantive UniversalSQL compliant variant." }, "ElasticApm": { "$ref": "ElasticApmConfig.schema.json", "description": "Gets the Elastic APM configuration." }, "MonitorUsers": { "anyOf": [ { "$ref": "Users.schema.json" }, { "type": "null" } ], "description": "User accounts for the interactive monitor." }, "CloudApi": { "anyOf": [ { "$ref": "CloudApiConfigModel.schema.json" }, { "type": "null" } ], "description": "The Invantive Cloud API connection configuration (when in Invantive Cloud mode)." }, "Local": { "anyOf": [ { "$ref": "LocalConfigModel.schema.json" }, { "type": "null" } ], "description": "The local configuration (when in local on-premises mode)." }, "Demo": { "anyOf": [ { "$ref": "DemoConfigModel.schema.json" }, { "type": "null" } ], "description": "The demo configuration (when in demo mode)." }, "Mode": { "$ref": "ServerModes.schema.json", "description": "The server mode.", "readOnly": true }, "Monitoring": { "anyOf": [ { "$ref": "MonitoringConfig.schema.json" }, { "type": "null" } ], "description": "The interactive monitoring configuration." } } } ```