Repository navigation
Redis simple dictionaries support direct layout - #106501
Conversation
|
Workflow [PR], commit [36a9077] Summary: ✅
AI ReviewSummaryThis PR fixes Redis dictionaries backed by Findings
Final VerdictStatus: Minimum required action: clarify the Redis dictionary source docs so the documented integer key support matches the implementation. |
bca3992 to
f7e10b7
Compare
| dict_struct.key->size()); | ||
|
|
||
| const auto & key = dict_struct.key->front(); | ||
| if (!isInteger(key.type) && !isString(key.type)) |
There was a problem hiding this comment.
Should we allow {U,}Int128{,256} here, looks like they will be wrapped with quotes, will it work?
There was a problem hiding this comment.
Wide ints fall under isIntegers, but seems suck keys forbdden in
https://github.com/ClickHouse/ClickHouse/blob/master/src/Core/ExternalResultDescription.cpp which is checked in RedisSource
| | `host` | The Redis host. | | ||
| | `port` | The port on the Redis server. | | ||
| | `storage_type` | The structure of internal Redis storage using for work with keys. `simple` is for simple sources and for hashed single key sources, `hash_map` is for hashed sources with two keys. Ranged sources and cache sources with complex key are unsupported. Default value is `simple`. Optional. | | ||
| | `storage_type` | The structure of the internal Redis storage used to work with keys. `simple` uses a flat key-value map and supports simple-key layouts as well as single-column complex-key layouts (such as `complex_key_cache` and `complex_key_direct`). `hash_map` uses a Redis hash and is required for composite complex keys; it expects exactly two key columns. Key columns must be of integer or string type. Ranged layouts are unsupported. Default value is `simple`. Optional. | |
There was a problem hiding this comment.
This overstates the supported key types. The code path still builds an ExternalResultDescription for the key column, and the new test asserts that UInt256 reaches Unsupported type UInt256, so users reading "integer" here will expect UInt128/UInt256 keys to work even though they do not. Please narrow this to the actual supported integer key types, for example Int8...Int64 and UInt8...UInt64, or reject wide integer keys at dictionary creation if they should remain unsupported.
LLVM Coverage Report
Changed lines: Changed C/C++ lines covered by tests: 32/42 (76.19%) | Lost baseline coverage: none · Uncovered code |
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Bad cast exceptionfor Redis dictionaries that useSTORAGE_TYPE 'simple'with acache/directlayout and a single string (complex) key; such dictionaries now work, and composite keys oversimplestorage report a clear error.Version info
26.6.1.696