-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Postgres Source - Unable to handle jsonb[] (regression) #29172
Comments
Grooming:
|
@haithem-souala - can you please share some examples of what this JSONb[] output looks like in BigQuery for both Destinations V1 and V2? Ideally, both a screenshot and CSV dump would be helpful, as we want to be very careful with escaping and quotes. Email would also work - I'm {firstname}@airbyte.io |
Fyi, in destination v1, it's working fine. Source (Postgres):
Destination V1
|
Any ETA? This issue prevent us from migrating the last DB. |
We were able to repro this issue in BigQuery and Snowflake and are investigating what the fix should be. It looks like Postgres arrays are defined with curly braces instead of brackets, and v2 is not recognizing this syntax? And maybe there is a discrepancy in when the data is deserialized?
Running the SQL that gets output in the V2 logs e.g. Normalization seemed to previously convert arrays to strings around here:
|
@haithem-souala are there any differences (other than the destinations v2 toggle) between your v1 and v2 connections? Specifically: is the v1 connection using CDC and the v2 connection using standard replication? I ran a v1 sync in standard replication and got the same behavior you're seeing in v2: And ran a v2 sync with CDC, which seems to have worked: I think this is a bug in source-postgres, trying to find the relevant issue. |
couldn't find an existing issue; submitted #29551 |
The V1 and V2 are both standard replication. The source-postgres version in V1 -> 1.0.30 I hope that will help debugging the bug. |
looks like 1.0.42 is the highest version of source-postgres that supports |
Unfortunately, i cannot downgrade source-postgres to 1.0.42, as it might affect other streams. |
can you explain some more on this? My understanding is that the two major releases between 1.x and 3.x were upgrading the underlying debezium library in 2.0.0 (which shouldn't affect non-CDC syncs) and changing how source-postgres's cursor works in CDC mode in 3.0.0 (which, again, only affects CDC syncs). also tagging in @prateekmukhedkar for DB sources expertise, in case I missed something in the changelog. |
Yeah, i don't know what changed "really" between the 1.0.42 and the 3.X, if someone can confirm the changes are related only to CDC mode, ill be down for a downgrade of the connector. |
Hey @prateekmukhedkar, we're migration the syncs to V2 destination, and this issue blocking us to migrate the last two sources. |
@haithem-souala source-postgres:3.1.9 has been released, which should work correctly for you - can you give it a try? |
Yes, it's working fine, thank you @edgao! |
Connector Name
destination-bigquery
Connector Version
1.7.2
What step the error happened?
During the sync
Revelant information
Normalization: raw data (json)
Source: Postgres v3.0.2
In table A (at Postgres) we have a field
tags
(jsonb[]), so the data stored, looks like this:Or like this:
The BigQuery Destination v2 connector, write the data in the
_airbyte_data
like this:In the final destination table, airbyte is unable to handle the
tags
field content, so it will be ignored with this message in the_airbyte_meta
:{"errors":["Problem with
tags
"]}Expected bahaviour:
Just set the field content in the final destination table.
Relevant log output
No response
Contribute
The text was updated successfully, but these errors were encountered: