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

chore(connect)!: drop support for node 14 and 16 #573

Merged
merged 6 commits into from
Nov 20, 2023

Conversation

TillaTheHun0
Copy link
Member

@TillaTheHun0 TillaTheHun0 commented Mar 24, 2023

Node 14 is out of LTS beginning in April.

Once we drop support for Node 14, we can do some cool stuff with Readable Streams

This would be a BREAKING CHANGE:

  1. drops support for Node 14 and 16

  2. instead of storage.download always returning a ReadableStream, it would instead always return a hyper response shape:

{
  ok: boolean,
  status?: number,
  object?: ReadableStream
}
  1. instead of storage.upload accepting a Uint8Array, it instead accepts a ReadableStream. This allows for streaming requests directly into storage.upload

To pass a Uint8Array into storage.upload, simply transform it into a ReadableStream. For example, using the built-in Response:

const arrBuffer = new Uint8Array(...)

const stream = new Response(arrBuffer).body

Closes #554

@TillaTheHun0 TillaTheHun0 marked this pull request as ready for review April 5, 2023 23:17
@TillaTheHun0 TillaTheHun0 force-pushed the tillathehun0/connect-drop-node-14 branch from 34775bb to 8dc6d7c Compare April 5, 2023 23:32
@TillaTheHun0 TillaTheHun0 force-pushed the tillathehun0/connect-drop-node-14 branch from 8dc6d7c to 5b6be1a Compare May 18, 2023 13:19
@TillaTheHun0 TillaTheHun0 force-pushed the tillathehun0/connect-drop-node-14 branch 2 times, most recently from 2998853 to 0cd9512 Compare June 1, 2023 15:36
@TillaTheHun0 TillaTheHun0 changed the title chore(connect)!: drop support for node 14 chore(connect)!: drop support for node 14 and 16 Nov 20, 2023
@TillaTheHun0 TillaTheHun0 force-pushed the tillathehun0/connect-drop-node-14 branch from 0cd9512 to 06d507d Compare November 20, 2023 17:05
@TillaTheHun0 TillaTheHun0 force-pushed the tillathehun0/connect-drop-node-14 branch from 06d507d to 09eb0ba Compare November 20, 2023 17:12
@TillaTheHun0 TillaTheHun0 force-pushed the tillathehun0/connect-drop-node-14 branch from b5f1dfc to 7a2ce78 Compare November 20, 2023 17:36
@TillaTheHun0 TillaTheHun0 force-pushed the tillathehun0/connect-drop-node-14 branch from e38c89b to 5d4703e Compare November 20, 2023 18:13
@TillaTheHun0 TillaTheHun0 merged commit 7e0958c into main Nov 20, 2023
8 checks passed
@TillaTheHun0 TillaTheHun0 deleted the tillathehun0/connect-drop-node-14 branch November 20, 2023 18:17
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

Successfully merging this pull request may close these issues.

bug: hyper storage returns stream of "Not found" JSON when object is not found
1 participant