By Orch8 Engineering · Editorial policy
Pass Large Files Between Workflow Steps
Persist a durable object identity, expected size, checksum, and access scope in workflow state. Have the worker obtain access when it runs. A temporary signed URL can expire during a workflow wait or after a worker is restarted.
What is the practical answer?
Persist a durable object identity, expected size, checksum, and access scope in workflow state. Have the worker obtain access when it runs. A temporary signed URL can expire during a workflow wait or after a worker is restarted. An artifact record can store bucket, object key, object version, media type, expected length, and a digest. Keep mutable objects behind explicit versions or write new immutable keys per generated result. With that contract, a worker can verify it opened the same file the upstream step produced, even if access credentials have changed. Use scoped worker credentials or issue a short-lived download URL at run time. Avoid storing signed URLs in long-lived logs or workflow history because they grant temporary access. When object retention is shorter than workflow retention, define how an expired input is recovered or surfaced.
Evidence: Amazon S3 presigned URL expiration and access · Reddit enterprise n8n and large-file processing discussion
- Receive object referenceInput
- Obtain fresh scoped accessProcess
- Verify version and checksumDecision
- Consume verified artifactExternal action
Keep identity and access separate#
Use scoped worker credentials or issue a short-lived download URL at run time. Avoid storing signed URLs in long-lived logs or workflow history because they grant temporary access. When object retention is shorter than workflow retention, define how an expired input is recovered or surfaced. Otherwise, an engine that preserves state can resume a run whose file is gone.
| What you find | What to do |
|---|---|
| Temporary URL expired | renew access for the same verified object version. |
| Stored digest differs from bytes received | hold processing and investigate the version. |
| Object retention removed the input | recover the original artifact or mark the run blocked. |
Treat checksum mismatch as a real failure#
Validate size and digest before using the artifact or publishing a result. Retrying is reasonable if the credential expired or the storage connection dropped. Missing versions and integrity mismatches require investigation. Include the artifact identity in output metadata so an operator can compare what was read with the original manifest.
Budget artifact lifetime across waits and retries#
Calculate the longest expected delay between upload and the final eligible retry, including approval waits and operational recovery. Keep the version available for that duration plus any contractual audit period that applies. Use short-lived worker access independently of the object’s retention. The reference can stay in workflow state after the access credential expires.
Use a result manifest containing input object version, integrity digest, worker version, output artifact version, and the originating execution. When two workers process the same object after a retry, they should converge on one accepted output intent or one explicit new revision. Verify that a failed attempt cannot replace a confirmed artifact with a partial file.
Verify it with a failure drill#
Create a test object, mint a short-lived URL, and resume the worker after it expires. Also test a fixture with a mismatched digest.
- Verify the worker obtains fresh access to the original object version and rejects the changed fixture before producing any downstream result.
Sources and further reading
Official references support technical claims; community discussions are used only as problem signals.