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

postgres data encoder refactor #161

Merged
merged 9 commits into from
Dec 13, 2019
Merged

postgres data encoder refactor #161

merged 9 commits into from
Dec 13, 2019

Conversation

tanner0101
Copy link
Member

@tanner0101 tanner0101 commented Dec 12, 2019

Refactors PostgresDataEncoder to be more flexible. There are now three distinct paths for encoding:

  • Single value: Cast to PostgresDataConvertible, if fail, unwrap and try again
  • Unkeyed value: Convert to JSONB[]
  • Keyed value: Convert to JSONB

This is achieved by encoding to a temporary structure. This structure can be analyzed when deciding how to proceed with encoding.

@tanner0101 tanner0101 added the enhancement New feature or request label Dec 12, 2019
@tanner0101 tanner0101 added the bug Something isn't working label Dec 12, 2019
@tanner0101 tanner0101 merged commit 8d3a5d3 into master Dec 13, 2019
@tanner0101 tanner0101 deleted the tn-array-coders branch December 13, 2019 22:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant