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

Optimization: Lazy date/timestamp parsing #1058

Open
stephenh opened this issue Apr 25, 2024 · 0 comments
Open

Optimization: Lazy date/timestamp parsing #1058

stephenh opened this issue Apr 25, 2024 · 0 comments

Comments

@stephenh
Copy link
Collaborator

In theory if we did:

  • Load row 1 from the database with date=2020-01-01
  • Postgres sends over all types as strings
  • We could delay/skip parsing the "2020-01-01" string into a Date/PlainDate until the user actually asked for that field
  • We could probably even have entityResolver realize that, if the pg string encoding happens to match our GQL wire format encoding, we could go pg-string -> graphql-output also without going through a Date/PlainDate instance
  • Could we do the same with fields as basic as ints? 🤔
@stephenh stephenh changed the title Optimization: Skip date/timestamp parsing Optimization: Lazy date/timestamp parsing Apr 26, 2024
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