Skip to main content

Connection Configuration

Summary

This page documents database connections, file connections, database links, and system connection JSON. These settings control how Velox connects to configuration/data/log databases and how it reads, writes, audits, transports, and names files.

Source Code Locations

  • Classes\vxDBCon.pas:17 - TvxDBCon.
  • Classes\vxDBCon.pas:190 - TvxDBCon.New defaults.
  • Classes\vxDBCon.pas:558 - database connection parameter application.
  • Classes\vxFileCon.pas:17 - TvxFileCon.
  • Classes\vxFileCon.pas:159 - TvxFileCon.New defaults.
  • Classes\vxFileCon.pas:193 - TvxFileCon.Reset runtime file state.
  • Classes\vxCon.pas:160 - Connections.json parsing.
  • Classes\vxDBParams.pas - system database parameter object.
  • Forms\frmSetupDBCon.pas:21 - TSetupDBCon.
  • Forms\frmSetupFileCon.pas:21 - TSetupFileCon.

Important Classes

  • TvxDBCon
  • TvxDBLink
  • TvxFileCon
  • TvxConnection
  • TvxDBParams

Important Forms

  • TSetupDBCon
  • TSetupFileCon
  • TDatabaseExplorer
  • TViewDBCons
  • TViewSysCons

Important Services

  • VeloxService uses connection modules during flow execution.
  • VeloxAPIService uses connection modules for API/runtime execution.
  • Connections.json in AppDataConfigPath.
  • Database tables: VX_DBCON, VX_FILECON.
  • Additional file connection columns: MAINFILEPATH, ERRORFILEPATH, ISSUEFILEPATH, DUPFILEPATH.

Database Connection Module Identity

SettingValid valuesDefaultImpact
TableInternal stringVX_DBCONSelects database connection table.
ModuleDescriptionInternal stringDB ConDisplay/module metadata.
ModuleNameStringNew DB ConUser-visible module name.

Database Connection Settings

SettingValid valuesDefaultImpact
ConnectionTypeTRegConTypectMSSQLSelects database engine and ReportBuilder database type.
DisconnectAfterUseBooleanFalseIndicates whether to disconnect after use. Exact call sites not fully traced here.
msoledbsqlBooleanTrueLegacy/compatibility flag for MSOLEDBSQL use. Transfer code maps this to SQLDriverType when older configs have no driver type.
SQLDriverTypeTvxSQLDriverTypefdtNotSetSQL Server driver selection; code comments indicate fdtNotSet lets legacy logic infer MSOLEDBSQL or SNAC11.
HostnameString, tags processed at connect time''Database server/host.
DatabaseString, tags processed at connect time''Database/catalog name.
SQLAuthTypeTvxSQLAuthTypeatWindowsAuthentication type.
UsernameString, tags processed at connect time''Database login user.
PasswordEncrypted persisted string; runtime getter decrypts and tags are processed at connect time''Database login secret.
ProviderNameString''Provider name for ADO/ODBC or database driver paths.
SearchADOBooleanFalseEnables ADO search behaviour in UI/runtime where used.
SearchODBCBooleanFalseEnables ODBC search behaviour in UI/runtime where used.
SQLDialectInteger1SQL dialect parameter passed into database configuration.
OtherParamsTStringList of key/value style parametersEmpty listAdditional database driver parameters; values are tag-processed before connection.
SQLTypeTppSQLTypesqSQL2ReportBuilder SQL type. For non-ODBC, getter returns type from ConTypeSQLTypeArray; for ODBC, stored value is used.
SingleQuoteDatesBooleanTrueSQL date formatting behaviour.
UseASAliasBooleanFalseSQL alias generation behaviour.
ForceAliasBooleanFalseSQL alias forcing behaviour.
UseSingleBackQuoteBooleanFalseSQL identifier quoting behaviour.
MySQLVersionTvxMySQLVerTypefmtClientMySQL driver mode. Old values are migrated during transfer.
SSLKeyFile path/string''Database SSL key.
SSLCertFile path/string''Database SSL certificate.
IsPersistantBooleanFalsePersistent connection/pool behaviour flag. Name is misspelled in code and persisted API.
MinConnectionsInteger0Minimum pool connection count.
MaxConnectionsInteger0Maximum pool connection count.
MaxTranPerUpdateInteger0Maximum transactions per update. Exact enforcement not fully traced here.
DisableTransactionsBooleanFalsePrevents vxStartTransaction, vxCommitTran, and vxRollbackTran from calling SQL transaction methods.
TrustCertificateBooleanFalsePassed to database parameter configuration; used for SQL certificate trust behaviour.
UseCCEBooleanTruePassed to SetMainParams and SetSubParams; exact meaning is not expanded in this unit.
TransIsolationForWritingTvxTransIsolationLevelftilREADCOMMITTEDTransaction isolation for writes.
TransIsolationForReadingTvxTransIsolationLevelftilREADCOMMITTEDTransaction isolation for reads.

TvxDBLink is embedded by definitions and scripts to reference a database connection module.

SettingValid valuesDefaultImpact
DBConFIDSGUID stringEmptyGuidPersisted database connection reference.
DBConNameString''Display name for the linked DB connection. Loaded resets default module names _Data and _Config for default GUIDs.

Default Database Connections

TvxDBCon.CreateDefaultDBConnection creates two special connections if absent:

ModuleFIDPurposeSource
_DataDefaultModuleGuidPoints to active data database from Connections.json.TvxDBCon.LoadDefaultConfig
_ConfigDefaultModuleGuid2Points to active configuration database from Connections.json.TvxDBCon.LoadDefaultConfig

File Connection Module Identity

SettingValid valuesDefaultImpact
TableInternal stringVX_FILECONSelects file connection table.
ModuleDescriptionInternal stringFile ConDisplay/module metadata.
ModuleNameStringNew File ConUser-visible module name.

File Connection Settings

SettingValid valuesDefaultImpact
FileNameString with tags supported at runtime''Output file naming template. <FILENO> and <COUNTER> are supported in ProcessFileName; data and runtime tags are also processed.
FilePatternFile search/pattern string with tags supported*Input search pattern and output save-name basis for transports.
FileDirFolder path with <DEFAULTDIR> and tags supported<DefaultDir>\Main file directory. Setter updates related default subfolders and enforces trailing delimiter.
AuditDirFolder path with <DEFAULTDIR> and tags supported<DefaultDir>\AUDIT\Destination for audited files.
TransportDirFolder path with <DEFAULTDIR> and tags supported<DefaultDir>\TRANSPORT\Destination for files awaiting outbound transport.
ErrorDirFolder path with <DEFAULTDIR> and tags supported<DefaultDir>\ERROR\Destination for errored files.
IssueDirFolder path with <DEFAULTDIR> and tags supported<DefaultDir>\ISSUE\Destination for issue files.
DuplicateDirFolder path with <DEFAULTDIR> and tags supported<DefaultDir>\DUPLICATE\Destination for duplicate files.
TempDirFolder path with <DEFAULTDIR> and tags supportedSet by SetFileDir to FileDir + TEMP\; not explicitly set in New before setter callsTemporary file directory.
EnableCounterBooleanFalseEnables database-backed counter increment for <COUNTER> naming.
UniqueFileNameBooleanTrueEnsures output/moved/copied file names are made unique rather than overwritten.
EnsureSafeFileNameBooleanTrueApplies MakeSafeFilename after tag processing for file names.
WaitForInteger seconds30Wait time for file lock release when reading files.
InboundFileNamingTvxInboundFileNamingffnUseIncomingControls how inbound transport downloads choose saved file names.

File Connection Runtime State

The following settings are not published module configuration, but they are important runtime configuration/state.

SettingValid valuesDefault/resetImpact
CurrentFileNameFile path string'' on resetTracks current file being processed.
NewFileNameFile name string'' on resetOne-use override for destination name. Getter clears it.
FilePathFile path string'' on resetExplicit file path used by service monitor processing. Getter clears it after use.
FileNoInteger1 on resetPer-run increment used by <FILENO>.
DoMoveToAuditBooleanFalse on resetControls post-processing audit move.
DoMoveToTransportBooleanFalse on resetControls move to transport folder and disables audit move when set.
DoMoveToErrorBooleanTrue on resetControls move to error folder. Defaults true so errors can move the file.
FileEventTvxFileEventTypefetNone on resetTracks file event for logs.
DataViewRecordNoCardinal0 on resetUsed when processing data tags into file names.

Default File Connection

TvxFileCon.CreateDefaultFileConnection creates _Default with DefaultModuleGuid when missing. It appends Temp\ to the default FileDir before saving.

System Connection JSON

The system connection JSON schema is documented in System and Runtime Configuration. It maps named configuration keys to active config/log/data database parameter objects.

Persistence Notes

  • TvxDBCon.Password stores encrypted values unless loading/reading component data.
  • TvxFileCon.BeforeAddModuleEvent and BeforeSaveModuleEvent persist processed folder paths to auxiliary columns.
  • TvxFileCon.CheckDirectories creates main, audit, issue, error, duplicate, and temp directories; it intentionally does not create transport folder by default.

Unclear Areas

  • UseCCE, MaxTranPerUpdate, and some SQL alias/formatting flags are passed into lower-level database helpers; the exact database-driver-specific effects were not fully traced in this pass.
  • SearchADO and SearchODBC appear to be UI/search aids; exact runtime impact is not fully traced here.