news.volyx.in

Postgres WASM (supabase.com)

887 points by kiwicopple · 1436 days ago · 185 comments on HN

Article summary

The article discusses the open-sourcing of Postgres WASM, a PostgreSQL server that runs inside a browser, developed by Snaplet and Supabase. This project allows for features such as persisting state to the browser, restoring from pg_dump, and logical replication from a remote database. The development of Postgres WASM involved overcoming technical hurdles, including compiling Postgres for WASM and establishing networking capabilities. The project has potential use cases in areas such as documentation, offline data analysis, and development environments.

Main themes

  • Postgres WASM
  • Browser-based databases
  • WASM optimization
  • Development environments
  • Offline data analysis
  • Map-based applications

What commenters say

  • Some commenters believe that a native WASM Postgres would be more efficient than the current emulated solution.
  • Others think that the current implementation is a good starting point, but there is room for optimization and improvement.
  • The use of Postgres WASM could enable new capabilities, such as running PostGIS in the browser, which could be beneficial for map-based applications.
  • Some commenters are skeptical about the practical use cases for Postgres WASM, given the existence of other data storage solutions like IndexedDB and WebSQL.
  • Others see potential use cases in areas such as training, interview challenges, and client-side tooling.
  • There are differing opinions on the value of running Postgres in the browser versus using a local or hosted database.
  • Some commenters suggest that compressing the WASM file using algorithms like Brotli or Zstandard could improve load times.