Convert PG Composite Types to Tuples in CH
Currently custom composite types from postgres are saved as strings in CH which makes it inconvenient to access/filter/sort/etc them. This PR adds functionality converting composite types to Tuple.
- Nested composite types and arrays of composites are supported
- Clickhouse doesn't have
Nullable(Tuple(...))so instead every field of tuple is createdNullable(ifPEERDB_NULLABLEis enabled) - Apparently this feature should be wrapped in setting to make existing mirrors won't break.
- I tested only the direct scenario, PG -> CH mirror. PG -> PG and others were not tested
#3066 introduced versioning as a simpler alternative to settings for maintaining backwards compatibility
wanted to get to bringing this to a point we can merge, but been falling behind this past month
wanted to get to bringing this to a point we can merge, but been falling behind this past month
I'm doing a bit of refactoring right now and fixing several issues. Will be ready for review in a day or 2.
Hi @serprex @heavycrystal, it's ready for reviewing. I've added a new version CompositeTypeAsTuple for backward compatibility and fixed several issues with arrays of composites and nested tuples.