Urgent.News

What's breaking now, across thousands of outlets.

Tech

Node.js Upload Storage Explained: Object Buckets Beyond Database Blobs and Local Disk

Short answer: for a small US/EU app, put avatar and large media bytes in private object storage, keep the object key and metadata in the database, and let the client transfer bytes with a presigned URL instead of routing the file through Node.js. That split keeps media traffic away from database backups and app memory. It also avoids tying an upload to one server's local disk when the app grows…

A small US/EU application can improve avatar and media uploads by utilizing private object storage rather than the database or local disk. The object key and metadata are stored in the database, while the actual bytes are transferred using a presigned URL from the client. This approach keeps media traffic separate from database backups and app memory, and prevents tying uploads to a single server's local disk as the application scales.

The main challenge lies in managing retries, orphan cleanup, egress, backups, observability, and potential changes to the storage provider. A control-plane option like Infrai can help manage private object operations with a stable REST contract. Its main advantage is portability, as the storage vendor can change without affecting the contract. Using a single key and bill can also simplify operations across a wider backend surface.

In terms of implementation, the client first sends the upload to the Node.js server for authorization. The server responds with a short-lived presigned URL, which the client then uses to upload the bytes directly to the object storage. The API records an object key, content type, owner, and status in the database. The binary is never stored in the database.

To monitor bucket usage, a separate program reads the usage data through the same API boundary used by the storage workflow. This program uses the required number of retries and backoff strategy when fetching the usage data from the Infrai API. The production flow includes additional steps for authorization and state transitions around the measurement.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

This story

This is one outlet's version. Read the fullest account.

Every outlet that reported this, and when →

Read the original at dev.to →

More in Tech

How to (not) Destroy Your SSD

37 TeraBytes in three weeks In June 2026 a Codex user opened an issue on the openai/codex repository with a set of numbers that did not seem to belong together.

  • Codex user discovered 37TB SSD writes in 3 weeks
  • SQLite database logging causes SSD wear
  • Apple lacks SSD endurance ratings for MacBooks

Restaurant Menu Retrieval Architecture in 2026: Freshness Windows and Reranking Trade-offs

The least complex design that stays trustworthy is a staged retrieval pipeline: search fresh sources, query a bounded collection, then rerank only the small candidate set.

  • Restaurant menu retrieval uses staged pipeline with fresh sources and reranking.
  • Explicit freshness window and source context maintained throughout process.
  • Architecture divided into fast and slow clocks with 15-minute freshness window.

More from Monday 16 November →