-
Notifications
You must be signed in to change notification settings - Fork 3.6k
[improve][io] support array schema for JDBC postgres connector #24549
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
…bcArrayIntegrationTest
…a for record handling
…n PostgresJdbcAutoSchemaSink
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, good work @freeznet
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #24549 +/- ##
============================================
+ Coverage 73.57% 74.30% +0.73%
- Complexity 32624 32630 +6
============================================
Files 1877 1874 -3
Lines 139502 146362 +6860
Branches 15299 16796 +1497
============================================
+ Hits 102638 108754 +6116
- Misses 28908 28967 +59
- Partials 7956 8641 +685
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
/pulsarbot run-failure-checks |
1 similar comment
/pulsarbot run-failure-checks |
pulsar-io/jdbc/core/src/main/java/org/apache/pulsar/io/jdbc/BaseJdbcAutoSchemaSink.java
Outdated
Show resolved
Hide resolved
…seJdbcAutoSchemaSink.java Co-authored-by: Omri Fried <[email protected]>
Fixes #xyz
Main Issue: #xyz
PIP: #xyz
Motivation
Currently, the JDBC PostgreSQL connector in Apache Pulsar doesn't support array schema types, limiting its ability to handle complex data structures. Many real-world applications require storing array data in PostgreSQL databases (e.g., tags, categories, multi-valued attributes).
Without this support, users have to:
This PR addresses these limitations by adding comprehensive array schema support for the PostgreSQL JDBC connector.
Modifications
Core PostgreSQL Array Implementation (
PostgresJdbcAutoSchemaSink.java
):Framework Enhancement (
BaseJdbcAutoSchemaSink.java
):handleArrayValue
for database-specific implementationsDatabase-Specific Support (
SqliteJdbcAutoSchemaSink.java
):Testing Infrastructure:
PostgresArrayTestUtils.java
) for generating test array dataPostgresJdbcArrayIntegrationTest.java
) covering:Verifying this change
(Please pick either of the following options)
This change is a trivial rework / code cleanup without any test coverage.
(or)
This change is already covered by existing tests, such as (please describe tests).
(or)
This change added tests and can be verified as follows:
(example:)
Does this pull request potentially affect one of the following parts:
If the box was checked, please highlight the changes
Documentation
doc
doc-required
Documentation should be updated to include:
doc-not-needed
doc-complete
Matching PR in forked repository
PR in forked repository: freeznet#13