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

Consider a lower level/more performant response representation #36

Open
milessabin opened this issue Jan 13, 2020 · 1 comment
Open
Labels
enhancement New feature or request performance question Further information is requested

Comments

@milessabin
Copy link
Member

milessabin commented Jan 13, 2020

Currently we construct responses as Circe JsonObjects. @djspiewak observed that this is very costly, and also most likely unnecessary given that we're constructing a single response value bottom up: we could just as easily glom byte arrays together rather than constructing an intermediate structured value.

Simply ripping out Circe (for this role, not everywhere) and replacing with something lower level should be fairly straightforward, but probably isn't an immediate priority.

A slightly more ambitious move would be to support response streaming (ie. start returning the response to the client as soon as the first bytes are available). This might involve some tricky scheduling of nested subqueries for the best results, but I think also should be possible.

@milessabin milessabin added enhancement New feature or request question Further information is requested performance labels Jan 13, 2020
@tpolecat
Copy link
Member

Not super concerned about this right now, but streaming seems like a really interesting problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request performance question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants