clickhouse-datasource icon indicating copy to clipboard operation
clickhouse-datasource copied to clipboard

Refactor `GetConverter` and handle `LowCardinality()` type

Open adamyeats opened this issue 9 months ago • 1 comments

Fixes #805. This PR does a few things:

  • Handles LowCardinality() data type correctly and adds tests
  • Adds a converter for String to handle the recursion in GetConverter correctly (is there a better way to do this? i guess there was a reason why there wasn't a converter there for String already, but adding one does allow us to do some recursiveness here)
  • Modifies defaultConvert to handle strings and add better handling for pointers and dereferencing them
  • Refactors GetConverter to make it a bit nicer (?)
  • Uses reflect.PointerTo instead of reflect.PtrTo, which is now deprecated

adamyeats avatar Apr 29 '24 17:04 adamyeats

Use the following command to run this PR with Docker at http://localhost:3000:

docker run --rm -p 3000:3000 grafana/plugin-builds:0d457e36bd31428776d1f2716df7a73f6aaff5a7pre

github-actions[bot] avatar Apr 29 '24 17:04 github-actions[bot]