NHacker Next
  • new
  • past
  • show
  • ask
  • show
  • jobs
  • submit
What if database branching was easy? (xata.io)
sastraxi 9 minutes ago [-]
I’ve done experiments using BTRFS and ZFS for local Postgres copy-on-write. You don’t need anything but vanilla pg and a supported file system to do it anymore; just clone the database using a template and a newish version of Postgres.

Looking at Xata’s technical deep dive, the site claims that we need an additional Postgres instance per replica and proposes a network file system to work around that. But I don’t really understand why that’s needed. Can someone explain to me my misunderstanding here?

comrade1234 26 minutes ago [-]
I was on a big team working on a giant oracle database over 25-years ago. I dont remember the term but each developer had their own playground of the giant database that wasn't affected by anyone else. The DB admin would set it up for each developer in just a few minutes so it definitely wasn't a copy. Then when a developer needed to reset and go back to the original db again it just took a few minutes. I just don't remember what it's called but I think Postgres has had it now for a few years.
tremon 4 minutes ago [-]
You don't actually need to physically copy data, just create a view for every table that does a replacing merge between the original read-only data and the developer's own copy. And you can put a trigger on the view to redirect writes to the same private-copy table, making the whole thing transparent to the user.

Not disputing that Oracle had something like this built-in, but it sounds like something that I could have whipped up in a day or so as a custom solution. I actually proposed a similar system to create anonymized datasets for researchers when I worked at a national archive institute.

Nihilartikel 19 minutes ago [-]
This kind of magic is the reason that I'm very itchy to be able to line up real work on Datomic or XTDB someday.
theaniketmaurya 17 minutes ago [-]
i was using neon and they had some similar feature but now using planetscale. would be curious to know how you all are doing it?
e7h4nz 7 minutes ago [-]
[dead]
Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact
Rendered at 13:14:18 GMT+0000 (Coordinated Universal Time) with Vercel.