mymarilyn / clickhouse-driver

ClickHouse Python Driver with native interface support
https://clickhouse-driver.readthedocs.io
Other
1.2k stars 214 forks source link

Possibility to disable automatic reconnect on failed ping. #452

Closed crazyproger closed 4 weeks ago

crazyproger commented 4 weeks ago

Problem: We use Clickhouse Cloud, where all servers are hidden behind a load balancer. Unfortunately, there is no possibility to specify which specific server you want to connect to. When reconnecting, there is a high probability of connecting to a different server.

For us, this is a problem because servers may have replication lag. In some parts of our ETL, this is crucial. To understand that a reconnection has occurred, we need to receive an error in the calling code.