Skip to content
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

atf: add null to type of non-key fields #219

Open
mdibaiee opened this issue Jul 5, 2023 · 0 comments
Open

atf: add null to type of non-key fields #219

mdibaiee opened this issue Jul 5, 2023 · 0 comments

Comments

@mdibaiee
Copy link
Member

mdibaiee commented Jul 5, 2023

It happens a lot that from SaaS connectors, we have fields that end up as null under specific circumstances.

We are considering marking all properties as nullable by adding null to their type if they are not a key. For keys we don't want to make them nullable.

This can be done using traverse_jsonschema and getting a list of primary keys, and then adding null to type of every non-primary-key field. A simple example usage of traverse_jsonschema: https://github.com/estuary/airbyte/blob/master/airbyte-to-flow/src/interceptors/fix_document_schema.rs#L197-L210

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

No branches or pull requests

1 participant