Connection fields
| Field | Required | Description |
|---|---|---|
account | yes | Snowflake account locator, e.g. xy12345.eu-central-1 |
username | yes | Snowflake user — needs SELECT on source schemas plus full DDL/DML on a Traffical-owned schema (see below) |
privateKey | yes | PEM-formatted RSA private key |
warehouse | yes | Compute warehouse to use (e.g. ANALYTICS_XS) |
database | yes | Default database (definitions can override in SQL) |
schema | no | Default schema |
role | no | Snowflake role to assume |
Creating the user, role, and Traffical schema
The pipeline reads from your source data and writes intermediate tables into a dedicated Traffical schema. Both kinds of access live on a single role.database: ANALYTICS and provide ANALYTICS.TRAFFICAL as the Traffical working schema.
Generating the key pair
On any machine with OpenSSL:traffical_key.pem contents, including the -----BEGIN PRIVATE KEY----- headers) into the Traffical connection form.
Store the private key file securely (or delete it after copying). Snowflake supports up to two keys per user, which makes rotation easy: add the new public key, swap the connection to the new private key, then remove the old public key.
Warehouse sizing
The pipeline runs short-lived queries. AnX-SMALL warehouse is plenty for most projects. If your fact tables are huge and the pipeline is the bottleneck:
- Bump to
SMALLorMEDIUM. Snowflake charges per second of warehouse uptime, but auto-suspend (60 seconds is typical) keeps idle cost low. - Use a dedicated warehouse for Traffical so it doesn’t compete for slots with other workloads.
- Watch the Pipeline → Runs view for slow runs — that’s where you’ll see if you’re sized wrong.
Recommended table design
Cluster on user/entity columns and partition implicitly via the natural ordering of inserts (Snowflake handles micro-partitions automatically):Example definitions
Assignment definition SQL:Network access
Snowflake is HTTPS-only. Traffical reaches it via the SQL API. No firewall setup is needed by default. If your Snowflake account has network policies, add Traffical’s egress IPs (listed in Settings → Warehouse) to the allowed list.Gotchas
- Lowercase column names. Snowflake folds unquoted identifiers to uppercase. The pipeline expects lowercase column names in the output of your SQL (
user_id,assigned_at, etc.), so use explicitAS user_idaliases as in the examples above. TIMESTAMP_TZvsTIMESTAMP_NTZ. UseTIMESTAMP_TZfor time columns to keep timezone handling unambiguous.- Key passphrases. Snowflake supports passphrase-protected keys, but the Traffical connection doesn’t — use an unencrypted key file.
- Account locator format. Make sure to include the region/cloud suffix (e.g.
xy12345.eu-central-1.aws). The connection will fail with a confusing error if it’s wrong.