All Projects → zeromicro → cds

zeromicro / cds

Licence: MIT license
Data syncing in golang for ClickHouse.

Programming Languages

go
31211 projects - #10 most used programming language
Vue
7211 projects
javascript
184084 projects - #8 most used programming language
SCSS
7915 projects
Makefile
30231 projects
shell
77523 projects

Projects that are alternatives of or similar to cds

Cds
Data syncing in golang for ClickHouse.
Stars: ✭ 501 (-40.29%)
Mutual labels:  clickhouse, bigdata, kafka-consumer
vulkn
Love your Data. Love the Environment. Love VULKИ.
Stars: ✭ 43 (-94.87%)
Mutual labels:  clickhouse, bigdata
columnify
Make record oriented data to columnar format.
Stars: ✭ 28 (-96.66%)
Mutual labels:  bigdata
appmetrica-logsapi-loader
A tool for automatic data loading from AppMetrica LogsAPI into (local) ClickHouse
Stars: ✭ 18 (-97.85%)
Mutual labels:  clickhouse
hadoopoffice
HadoopOffice - Analyze Office documents using the Hadoop ecosystem (Spark/Flink/Hive)
Stars: ✭ 56 (-93.33%)
Mutual labels:  bigdata
uptrace
Open source APM: OpenTelemetry traces, metrics, and logs
Stars: ✭ 1,187 (+41.48%)
Mutual labels:  clickhouse
kafka-workers
Kafka Workers is a client library which unifies records consuming from Kafka and processing them by user-defined WorkerTasks.
Stars: ✭ 30 (-96.42%)
Mutual labels:  kafka-consumer
datacatalog-tag-manager
Python package to manage Google Cloud Data Catalog tags, loading metadata from external sources -- currently supports the CSV file format
Stars: ✭ 17 (-97.97%)
Mutual labels:  bigdata
awesome-clickhouse
A curated list of awesome ClickHouse software.
Stars: ✭ 71 (-91.54%)
Mutual labels:  clickhouse
coolplayflink
Flink: Stateful Computations over Data Streams
Stars: ✭ 14 (-98.33%)
Mutual labels:  bigdata
Proton
High performance Pinba server
Stars: ✭ 27 (-96.78%)
Mutual labels:  clickhouse
learning-spark
Tidy up Spark and Hadoop tutorials.
Stars: ✭ 28 (-96.66%)
Mutual labels:  bigdata
ClickHouseTools
Инструменты обслуживания и разработки для Yandex ClickHouse, а также другие интересности
Stars: ✭ 16 (-98.09%)
Mutual labels:  clickhouse
flink-learn
Learning Flink : Flink CEP,Flink Core,Flink SQL
Stars: ✭ 70 (-91.66%)
Mutual labels:  bigdata
openreplay
📺 OpenReplay is developer-friendly, open-source session replay.
Stars: ✭ 6,131 (+630.75%)
Mutual labels:  clickhouse
onelinerhub
2.5k code solutions with clear explanation @ onelinerhub.com
Stars: ✭ 645 (-23.12%)
Mutual labels:  clickhouse
chtable
Grafana's table plugin for ClickHouse
Stars: ✭ 26 (-96.9%)
Mutual labels:  clickhouse
bigdata-tech-index
Big Data Technology Index
Stars: ✭ 24 (-97.14%)
Mutual labels:  bigdata
trickster
Open Source HTTP Reverse Proxy Cache and Time Series Dashboard Accelerator
Stars: ✭ 1,753 (+108.94%)
Mutual labels:  clickhouse
awesome-bigdata
A curated list of awesome big data frameworks, ressources and other awesomeness.
Stars: ✭ 11,093 (+1222.17%)
Mutual labels:  bigdata

ClickHouse Data Synchromesh

Data syncing in golang for ClickHouse.

based on go-zero

ARCH

Data workflow of a typical data warehouse architecture

avatar

Design of Data Sync

Automatically synchronizing data from MySQL/MongoDB data source to ClickHouse cluster in real time(< 2min).

sync

start up

git clone https://github.com/zeromicro/cds.git
cd cds
make up

After the build , pay attention to check if any container exits abnormally.

click http://localhost:3414/cds.html to accessing the web interface.

using username and password below to login

user: [email protected]
password: 123456

create table in ClickHouse for syncing MySQL(or MongoDB) data

Chose "create table" tab

1. Click "Target ClickHouse Database Info",
2. Click “connect”
3. Select the schema ("default") synchronized to Clickhouse
4. switch to "Data Source" 
5. MySQL input connection string root:root@tcp(mysql:3306)/test_mysql
or
MongoDB input connection string mongodb://mongo1:30001/test_mongo
6. Click “connect”
7. Select the table, such as the default example_mysql (MySQL) or example (MongoDB)
8. click "Generate create Table SQL" 
 Note: select the partition field as needed, here'PARTITION BY toYYYYMM()' can be deleted, or replaced with'PARTITION BY toYYYYMM(dt)'
9. . Click "send SQL to ClickHouse", and the successful execution will pop up below

One-time full data synchronization:

Chose "full sync" tab

1. Click "+" in the upper right corner
2. MySQL input connection string root:root@tcp(mysql:3306)/test_mysql
or
MongoDB input connection string mongodb://mongo1:30001/test_mongo
3. Click “connect”
4. Select the table, such as the default example_mysql (MySQL) or example (MongoDB)
5. Click "Target ClickHouse Database Info"
6. Click “connect”
7. Select the schema ("default") synchronized in Clickhouse
10. Click "Add", a pop-up below shows successful execution

check task status

Refresh the page

Confirm data in Clickhouse

image-20201118135156133

Turn on real-time incremental synchronization

Take mysql as an example

chose "Connector" tab

1. Click "+" in the upper right corner
2. MySQL input connection string root:root@tcp(mysql:3306)/test_mysql
3. select table 
4. Click "Add"

chose "Incremental Sync" tab

1. Click "+" in the upper right corner
2. MySQL input connection string root:root@tcp(mysql:3306)/test_mysql
3. select table 
4. Click "Target ClickHouse Database Info"
5. Click “connect”
6. Select the schema ("default") synchronized in Clickhouse
7. Click "Add", a pop-up below shows successful execution

refresh page

Verify incremental update

Execute the initialization database script again, you can insert 100000 rows of data again.

cd sit/docker/
sh ./init.sh

Verify the incremental data of mysql in clickhouse:

image-20201118135503830

clean up

To clean up all the docker containers started above and restore the initial state, you can :

cd cds
make down

only clean

cd cds
make docker_clean

data model in clickhouse

CDS中ClickHouse使用的建表方案

help

提问的智慧

如何有效的报告bug


if you like this project and want to support it,please star 🤝

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].