Skip to content

Let a long Files upload keep going past Node's 5 minute request limit - #935

Merged
calledtoconstruct merged 1 commit into
MyOwnDataCenter:mainfrom
nixfred:fix/upload-timeout
Dec 5, 2026
Merged

calledtoconstruct merged 1 commit into
MyOwnDataCenter:mainfrom
nixfred:fix/upload-timeout

Conversation

@nixfred

@nixfred nixfred commented Nov 23, 2026 •

Copy link
Copy Markdown
Collaborator

What this changes

A Files upload, a container file, and a file sent to a joined computer can take up to 12 hours to arrive. That is the ceiling the upload relay already used. Every other request body still stops at Node's 5 minutes. The longer limit lasts only while an upload body is arriving, then the 5 minutes return. Headers keep their own limit.

This replaces the earlier draft, which turned the limit off for every request.

Fixes #485.

How you tested it

  • npm run typecheck, npm run build and npm test pass
  • Tried on a real Omarchy machine or VM (say which), if it touches install.sh, the helper, apps, machines or storage

test/upload-body.test.mjs passed (3 tests): a slow body that is not an upload is cut off, a slow upload body is accepted, and two overlapping uploads keep the longer limit until both finish. node --check passed for the touched files. Full npm test, typecheck, and build were not run.

Anything to know

The 12 hour ceiling matches AbortSignal.timeout(12 hours) in the Files upload relay. A container upload still stops at its own 30 minutes, and a joined-computer file is still refused past 20 MB. Version and What's New are unchanged.

@calledtoconstruct

Copy link
Copy Markdown
Collaborator

@nixfred Thank you. A long upload should be able to finish. I am leaving this as a draft.

requestTimeout = 0 removes the limit on the whole request. The note in the change says a body that trickles in can hold the connection open. That is a slow-request hold on the public server. Headers keeping their own limit does not bound the body.

A long upload needs a bound that still fits a real file: a generous request limit, or an idle timeout that resets while bytes arrive, with the signed-in upload route as the only place that waits. An unlimited timeout on both servers stays held. It also conflicts with main.

Node still stops every other request body at 5 minutes. A Files upload, a container file, and a joined-computer file widen that limit only while the body is arriving, then put it back. The ceiling is the 12 hours the upload relay already uses. Headers keep their own limit.

Fixes MyOwnDataCenter#485

Co-Authored-By: Grok 4.7
@calledtoconstruct
calledtoconstruct marked this pull request as ready for review December 5, 2026 13:19
@calledtoconstruct
calledtoconstruct merged commit 4f42c05 into MyOwnDataCenter:main Dec 5, 2026
2 of 3 checks passed
@calledtoconstruct

Copy link
Copy Markdown
Collaborator

Thank you @nixfred for catching the 5 minute cutoff and for the draft. A long upload now has the same 12 hour ceiling the relay already used, and only while the file is arriving. Merged.

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.

Files: any upload that takes longer than 5 minutes is cut off with a 408

2 participants