Commit ad2e81a
fix(clickhouse): address PR #157 review findings
- Catalog mode is now best-effort (mirrors DynamoDB): a table whose
schema fetch fails (broken view, permissions gap) is skipped with a
warning instead of failing server startup. Stream-like engine tables
(Kafka/RabbitMQ/NATS/FileLog) and materialized-view inner tables
(.inner* names) are filtered out up front.
- Introspection is one batched system.tables query instead of one
query per database, so many databases no longer blow the single
5s retry window. Adds a direct dep on the same `clickhouse` client
crate the upstream provider already uses.
- URL-embedded credentials are a hard config error instead of a
warning: the pool ignores them (auth would fail confusingly late)
and the connection string is logged and exposed by the data-sources
API. Connection strings are validated before they are logged.
- `database` joins `table`/`schema` in the catalog-mode conflicting
options list; added ClickHouse config-validation tests (read_write
rejection, database-in-catalog rejection).
- count(*) empty-projection scans stream the narrowest fixed-width
column instead of column 0; the no-aggregate-pushdown limitation is
documented in the README.
- Per-table schema inference is wrapped in retry_with_timeout so a
hanging endpoint can't stall startup.
- Docs: schema inference is a SELECT ... LIMIT 0 probe, not DESCRIBE
TABLE; federated_stock_value rounds stock_value to match the README.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>1 parent 26e43d4 commit ad2e81a
6 files changed
Lines changed: 285 additions & 64 deletions
File tree
- crates
- server/src
- skardi
- src/sources/providers
- docs/clickhouse
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
29 | 30 | | |
30 | 31 | | |
31 | 32 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
761 | 761 | | |
762 | 762 | | |
763 | 763 | | |
| 764 | + | |
764 | 765 | | |
765 | 766 | | |
766 | 767 | | |
767 | | - | |
| 768 | + | |
768 | 769 | | |
769 | 770 | | |
770 | 771 | | |
| |||
2374 | 2375 | | |
2375 | 2376 | | |
2376 | 2377 | | |
| 2378 | + | |
| 2379 | + | |
| 2380 | + | |
| 2381 | + | |
| 2382 | + | |
| 2383 | + | |
| 2384 | + | |
| 2385 | + | |
| 2386 | + | |
| 2387 | + | |
| 2388 | + | |
| 2389 | + | |
| 2390 | + | |
| 2391 | + | |
| 2392 | + | |
| 2393 | + | |
| 2394 | + | |
| 2395 | + | |
| 2396 | + | |
| 2397 | + | |
| 2398 | + | |
| 2399 | + | |
| 2400 | + | |
| 2401 | + | |
| 2402 | + | |
| 2403 | + | |
| 2404 | + | |
| 2405 | + | |
| 2406 | + | |
| 2407 | + | |
| 2408 | + | |
| 2409 | + | |
| 2410 | + | |
| 2411 | + | |
| 2412 | + | |
| 2413 | + | |
| 2414 | + | |
| 2415 | + | |
| 2416 | + | |
| 2417 | + | |
| 2418 | + | |
| 2419 | + | |
| 2420 | + | |
| 2421 | + | |
| 2422 | + | |
| 2423 | + | |
| 2424 | + | |
| 2425 | + | |
| 2426 | + | |
| 2427 | + | |
| 2428 | + | |
| 2429 | + | |
| 2430 | + | |
| 2431 | + | |
| 2432 | + | |
| 2433 | + | |
| 2434 | + | |
| 2435 | + | |
| 2436 | + | |
| 2437 | + | |
| 2438 | + | |
| 2439 | + | |
| 2440 | + | |
| 2441 | + | |
| 2442 | + | |
| 2443 | + | |
2377 | 2444 | | |
2378 | 2445 | | |
2379 | 2446 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
62 | 65 | | |
63 | 66 | | |
64 | 67 | | |
| |||
0 commit comments