2019-04-21 08:04:41 +03:00
|
|
|
# Basic information
|
2020-02-06 11:39:56 +03:00
|
|
|
## About
|
2019-04-21 08:04:41 +03:00
|
|
|
This project's goal is to build [Yandex ClickHouse](https://clickhouse.yandex/) database into [Django](https://www.djangoproject.com/) project.
|
|
|
|
It is based on [infi.clickhouse-orm](https://github.com/Infinidat/infi.clickhouse_orm) library.
|
|
|
|
|
2020-02-06 11:39:56 +03:00
|
|
|
## Features
|
2019-04-21 08:04:41 +03:00
|
|
|
* Multiple ClickHouse database configuration in [settings.py](https://docs.djangoproject.com/en/2.1/ref/settings/)
|
|
|
|
* ORM to create and manage ClickHouse models.
|
|
|
|
* ClickHouse migration system.
|
|
|
|
* Scalable serialization of django model instances to ORM model instances.
|
|
|
|
* Effective periodical synchronization of django models to ClickHouse without loosing data.
|
|
|
|
* Synchronization process monitoring.
|
|
|
|
|
2020-02-06 11:39:56 +03:00
|
|
|
## Requirements
|
2019-04-21 08:04:41 +03:00
|
|
|
* [Python 3](https://www.python.org/downloads/)
|
|
|
|
* [Django](https://docs.djangoproject.com/) 1.7+
|
|
|
|
* [Yandex ClickHouse](https://clickhouse.yandex/)
|
|
|
|
* [infi.clickhouse-orm](https://github.com/Infinidat/infi.clickhouse_orm)
|
2021-07-06 08:19:12 +03:00
|
|
|
* [pytz](https://pypi.org/project/pytz/) for python before 3.3
|
|
|
|
* [typing](https://pypi.org/project/typing/) for python before 3.5
|
2020-02-06 11:39:56 +03:00
|
|
|
* [psycopg2](https://www.psycopg.org/)
|
|
|
|
* [celery](http://www.celeryproject.org/)
|
|
|
|
* [statsd](https://pypi.org/project/statsd/)
|
2019-04-21 08:04:41 +03:00
|
|
|
|
|
|
|
### Optional libraries
|
2020-02-06 11:39:56 +03:00
|
|
|
* [redis-py](https://redis-py.readthedocs.io/en/latest/) for [RedisStorage](storages.md#redisstorage)
|
2019-09-16 19:22:53 +03:00
|
|
|
* [django-pg-returning](https://github.com/M1hacka/django-pg-returning)
|
2019-04-21 08:04:41 +03:00
|
|
|
for optimizing registering updates in [PostgreSQL](https://www.postgresql.org/)
|
2019-09-16 19:22:53 +03:00
|
|
|
* [django-pg-bulk-update](https://github.com/M1hacka/django-pg-bulk-update)
|
2020-02-06 11:39:56 +03:00
|
|
|
for performing effective bulk update and create operations in [PostgreSQL](https://www.postgresql.org/)
|
2019-04-21 08:04:41 +03:00
|
|
|
|
2020-02-06 11:39:56 +03:00
|
|
|
## Installation
|
2019-04-21 08:04:41 +03:00
|
|
|
Install via pip:
|
2020-02-07 15:57:51 +03:00
|
|
|
`pip install django-clickhouse`
|
2019-04-21 08:04:41 +03:00
|
|
|
or via setup.py:
|
|
|
|
`python setup.py install`
|