S
Supabase3w ago
Joe

ClickHouse FDW connection error

Getting the following error when trying to view a foreign material view from clickhouse using the supabase FDW.
Failed to retrieve rows from table
Error: Driver error: `Timeout error.`
Failed to retrieve rows from table
Error: Driver error: `Timeout error.`
Setup the FDW in the dashboard which requires minimal inputs. So unless I input the connection string incorrectly, not clear on what might be the issue and haven't discovered any docs that would guide further. Here's the current input for the ClickHouse Connection String
tcp://<username>:<password>@<clickhouse_host_id>.us-east-2.aws.clickhouse.cloud:9000
tcp://<username>:<password>@<clickhouse_host_id>.us-east-2.aws.clickhouse.cloud:9000
4 Replies
ihm40
ihm403w ago
On this page https://supabase.com/docs/guides/database/extensions/wrappers/clickhouse i noticed that the connection string can take additional parameters with some examples given
tcp://user:password@host:9000/clicks?compression=lz4&ping_timeout=42ms
tcp://default:PASSWORD@abc.eu-west-1.aws.clickhouse.cloud:9440/default?connection_timeout=30s&ping_before_query=false&secure=true
tcp://user:password@host:9000/clicks?compression=lz4&ping_timeout=42ms
tcp://default:PASSWORD@abc.eu-west-1.aws.clickhouse.cloud:9440/default?connection_timeout=30s&ping_before_query=false&secure=true
ihm40
ihm403w ago
Perhaps might be worth seeing if you can set a higher timeout?
Joe
JoeOP3w ago
I had gone through those docs and tried some different params. Didnt work earlier today, but its finally working now by using port 9440 and including secure=true without any other params. Also had UUIDs passing into clickhouse that aren't supported. Updated those cols to use strings before retrying the connection string params. Not sure if that had any impact on the connection errors.
ihm40
ihm403w ago
Hmm i'm surprised that clickhouse does not support uuid, the docs here suggest they do https://supabase.com/docs/guides/database/extensions/wrappers/clickhouse#:~:text=uuid-,UUID,-boolean%5B%5D did you find something else that suggests otherwise?

Did you find this page helpful?