MySQL Driver Documentation
This documentation explains the MySQL driver implementation and how connection parameters map to UI fields in the Gigantic application.
Connection Parameters
| UI Field | Technical Implementation | Description | Required | Default Value |
|---|---|---|---|---|
| Host | host in mysql2 connection config | The hostname or IP address of the MySQL server | Yes | localhost |
| Port | port in mysql2 connection config | The port number MySQL server is listening on | Yes | 3306 (from driverPorts) |
| Database | database in mysql2 connection config | The name of the database to connect to | Yes | None (must be specified) |
| Username | user in mysql2 connection config | Database user for authentication | Yes | None (must be specified) |
| Password | password in mysql2 connection config | Password for the database user | Yes | None (must be specified) |
Technical Details
The MySQL driver implementation uses the mysql2 Node.js library. Connection parameters are passed directly to the mysql2 library's connection configuration.
When SSH tunneling is enabled, connections are first established through the tunnel before connecting to the MySQL server.
Authentication Options
MySQL supports standard username/password authentication.
| Auth Type | UI Mapping | Description |
|---|---|---|
| None | Not applicable for MySQL | Disables authentication |
| Password | Username/Password fields | Standard username/password authentication |
| Password Manager | Various password manager fields | Fetches credentials from external password managers |
SSH Tunnel Support
The MySQL driver supports SSH tunneling for secure access to databases behind firewalls or in private networks. For detailed information on configuring SSH tunnels, please refer to the SSH Tunnelling documentation.
API Endpoints Used
MySQL connections are primarily used in:
- Tap creation (data source discovery)
- Sink creation (data destination for anonymized data)
- Pipeline execution (data extraction and loading)
Custom Params
The MySQL driver supports additional custom parameters that can be specified in YAML format to fine-tune connection behavior, pooling, SSL settings, and other advanced options.
Connection Parameters
# SSL Configuration
ssl:
rejectUnauthorized: false
ca: |
-----BEGIN CERTIFICATE-----
# CA certificate content
-----END CERTIFICATE-----
key: |
-----BEGIN PRIVATE KEY-----
# Client private key content
-----END PRIVATE KEY-----
cert: |
-----BEGIN CERTIFICATE-----
# Client certificate content
-----END CERTIFICATE-----
ciphers: "ECDHE-RSA-AES256-SHA:AES256-SHA"
minVersion: "TLSv1.2"
maxVersion: "TLSv1.3"
# Authentication Parameters
password1: additional_password # 1st factor authentication
password2: otp_code # 2nd factor authentication
password3: biometric_data # 3rd factor authentication
# Advanced connection options
connectTimeout: 10000
charset: "UTF8MB4_UNICODE_CI"
compress: true
multipleStatements: false
timezone: "+00:00"
enableKeepAlive: true
keepAliveInitialDelay: 10000
supportBigNumbers: true
bigNumberStrings: true
dateStrings: falsePool Configuration
# Pool sizing options
connectionLimit: 10
maxIdle: 10
# Pool timeout options
idleTimeout: 60000
queueLimit: 0
# Pool behavior options
waitForConnections: trueExample Configurations
SSL Configuration
ssl:
rejectUnauthorized: true
ca: ${file:/path/to/ca-cert.pem}
cert: ${file:/path/to/client-cert.pem}
key: ${file:/path/to/client-key.pem}Advanced Configuration with Big Number Support
supportBigNumbers: true
bigNumberStrings: true
decimalNumbers: true
timezone: "UTC"
connectionLimit: 15
idleTimeout: 30000