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

Switch akka-http to just exposing a stream for file uploads instead of buffering to disk #1308

Open
blast-hardcheese opened this issue Nov 1, 2021 · 0 comments

Comments

@blast-hardcheese
Copy link
Member

Semantics need to be addressed, but:

  • http4s and dropwizard both do streaming file uploads, not disk-backed
  • multi-file uploads for a single endpoint are rare use cases, maybe can be supported through special opt-in
  • mandated, per-route file handling methods are cumbersome

One issue is that if files are not the final element in the payload, (multipart form-data, for instance), we will run into a situation where we cannot call the application code before the stream has been consumed. Currently this is handled by filesystem-backed buffer, so an attempt to change this without a transition period will cause currently functional requests to start failing. This should be handled delicately, either by an option with a deprecation cycle, at the very least migration notes that go along with the new function signatures.

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