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

[GOT-51] Allow for multiple, parallelized read queries within a single call #436

Open
dtbuchholz opened this issue Jan 18, 2023 · 0 comments
Labels
enhancement New feature or request linear Sync issue with linear

Comments

@dtbuchholz
Copy link
Contributor

dtbuchholz commented Jan 18, 2023

Is your feature request related to a problem? Please describe.
With read queries, you can only pass one SELECT statement at a time. This leads to UX issues at the application level as well as DX. For example, if a webpage has some visual that relies on multiple, unrelated read queries, they must independently send one query at a time. Thus, the page has to wait for multiple responses before rendering the UI.

Describe the solution you'd like
Parallelize table reads so that multiple SELECT statements can be passed to a single read query, returning a single object that wraps all of the table responses. As noted by @carsonfarmer, this is a Validator API enhancement that would then have a downstream impact on both the SDK and CLI, but it is something the D1 API supports.

Describe alternatives you've considered
Developers could maybe try to implement their own multithreading approach, but this adds complexity and detracts from the DX.

Additional context
The request is coming from a developer that has a production application ready to go from a write perspective (i.e., tables are minted), but their hold up is related to read queries, as described above.

GOT-51

@dtbuchholz dtbuchholz added the enhancement New feature or request label Jan 18, 2023
@brunocalza brunocalza added the linear Sync issue with linear label Mar 23, 2023
@brunocalza brunocalza changed the title Allow for multiple, parallelized read queries within a single call [GOT-51] Allow for multiple, parallelized read queries within a single call Mar 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request linear Sync issue with linear
Projects
None yet
Development

No branches or pull requests

2 participants