Skip to content

[Postgres Support 1/5] Build/CI & Core Data Type Fixes#1265

Open
minguyen9988 wants to merge 3 commits into2.9.1from
minguyen/postgres-pr1-build-ci-datatype-fixes
Open

[Postgres Support 1/5] Build/CI & Core Data Type Fixes#1265
minguyen9988 wants to merge 3 commits into2.9.1from
minguyen/postgres-pr1-build-ci-datatype-fixes

Conversation

@minguyen9988
Copy link
Copy Markdown
Collaborator

Summary

Build configuration fixes and core data type mapping improvements for PostgreSQL support.

Part 1 of 5 PRs split from #1245 for reviewability.

Changes

  • pom.xml: Fix testSourceDirectory path (was src/test, now src/test/java) — fixes SecurityException: Prohibited package name
  • DateTime64 UTC timezone: All DateTime64 types now include explicit 'UTC' timezone to prevent DST corruption
  • PostgreSQL data type mapping: Added mappings for TIMESTAMPTZ, TIMETZ, UUID, BYTEA, JSONB, SERIAL/BIGSERIAL, TEXT, CHARACTER VARYING, BOOLEAN, NUMERIC/DECIMAL with precision
  • CI workflow: Added PostgreSQL integration test job to GitHub Actions
  • Test fixes: Updated 5 test assertions to match new UTC timezone in DateTime64

Files (15 files, +489/−57)

  • sink-connector/pom.xml
  • sink-connector/src/main/java/com/altinity/clickhouse/sink/connector/converters/ClickHouseDataTypeMapper.java
  • sink-connector/src/test/java/.../ClickHouseDataTypeMapperDDLTest.java
  • sink-connector/src/test/java/.../ClickHouseTableOperationsBaseTest.java
  • .github/workflows/ CI configs
  • Various connector type/config files

Review Notes

  • Self-contained, no dependencies on other PRs in this series
  • All 154 unit tests pass after these changes

@minguyen9988 minguyen9988 force-pushed the minguyen/postgres-pr1-build-ci-datatype-fixes branch from 040eaae to 2bb1041 Compare March 16, 2026 05:38
@minguyen9988 minguyen9988 force-pushed the minguyen/postgres-pr1-build-ci-datatype-fixes branch from 2bb1041 to 4be0808 Compare March 16, 2026 09:30
minguyen9988 and others added 2 commits March 16, 2026 05:17
Cherry-pick ClickHouseAutoCreateTable.java from minguyen/postgres to
remove NULL/NOT NULL modifiers when types are already Nullable().
Add ColumnTypeOverrideReconciler and ColumnTypeOverrideMismatchException
dependencies. Update test expectations to match new DDL output.
The JDBC getMetaData().getColumns() approach does not properly filter
by database in ClickHouse (databases map to catalogs, not schemas),
causing testGetColumnsDataTypesForTable to fail.

Restore the system.columns direct query approach from minguyen/postgres
which correctly filters by database and table name, and preserves the
Nullable() wrapper in type names.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant