Skip to content
Open Data Sync ↗

ClickHouse

ClickHouse is a sink in Data Sync: changes from any source are written into tables in a ClickHouse database, for analytical queries over fresh data. There is no ClickHouse source.

Sink Native protocol

Overview

Data Sync connects to ClickHouse on its native TCP port, 9000 by default, not the HTTP interface on 8123. The port must be reachable from the runner.

Before you connect

  1. Create the database Data Sync will write into, or use default.
  2. Open the native port from the runner to the server.
  3. Create a user for Data Sync that can insert into the target tables, and create them if you let Data Sync create tables.
-- a user Data Sync can write with CREATE USER pulse IDENTIFIED BY '…'; GRANT CREATE TABLE, INSERT, SELECT ON analytics.* TO pulse;

Connection fields

Set once, on the connection, in step 2 of the add-a-connection wizard.

FieldDefaultDescription
hostRequired—Hostname or address of the ClickHouse server.
portOptional9000The native protocol port.
databaseOptionaldefaultThe database tables are written into.
clusterAdvanced—The cluster name, when the database is spread across a ClickHouse cluster.

Credentials

Step 3 asks for a username and password. Both are optional in the form, because a server can allow the passwordless default user, but any server you write production data to should require them. Store them as a Blunox-managed secret or as a reference to your own secret store. See Connections.