TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Thin PostgreSQL Clones

114 点作者 samokhvalov超过 3 年前

10 条评论

krab超过 3 年前
If you&#x27;re interested how it works (and how to possibly implement it by yourself), I wrote about the idea a few years ago. [1] To Postgres, recovering as a clone looks the same as if someone suddenly unplugged the computer power cable.<p>The shell script that implements the idea with LVM snapshots (relies on an existing Postgres physical replica) is not too long. It&#x27;s used over SSH.<p><pre><code> $ wc -l &#x2F;usr&#x2F;local&#x2F;bin&#x2F;snapshot-* 164 &#x2F;usr&#x2F;local&#x2F;bin&#x2F;snapshot-create 16 &#x2F;usr&#x2F;local&#x2F;bin&#x2F;snapshot-drop 180 total </code></pre> Had this tool existed at the time, I&#x27;d have probably used it (monitoring and REST API might be handy). Still, the core idea can be implemented very easily.<p>[1]: <a href="https:&#x2F;&#x2F;www.sedlakovi.org&#x2F;blog&#x2F;2019&#x2F;03&#x2F;fast-postgres-snapshots.html" rel="nofollow">https:&#x2F;&#x2F;www.sedlakovi.org&#x2F;blog&#x2F;2019&#x2F;03&#x2F;fast-postgres-snapsho...</a>
vosper超过 3 年前
It’s a tool that clones Postgres databases. It’s not a clone of Postgres the application.
评论 #30071982 未加载
评论 #30078310 未加载
评论 #30071168 未加载
antihero超过 3 年前
Does this have something to handle potential PII? One of the problems with using prod data for development and testing is that it is often contains sensitive strings which need to be scrubbed somehow.
评论 #30072878 未加载
MDcker超过 3 年前
This blueprint about Database Lab from GitLab is quite interesting to understand the use case and what benefits it brings: <a href="https:&#x2F;&#x2F;docs.gitlab.com&#x2F;ee&#x2F;architecture&#x2F;blueprints&#x2F;database_testing&#x2F;" rel="nofollow">https:&#x2F;&#x2F;docs.gitlab.com&#x2F;ee&#x2F;architecture&#x2F;blueprints&#x2F;database_...</a>
rdsubhas超过 3 年前
This is simply great for master data &amp; content management. Fast clone, override&#x2F;mask data for QA&#x2F;dev&#x2F;test.<p>All that&#x27;s left is to diff what&#x27;s changed between clone and main database, and merge the changes back up for a full, safe workflow for master data and content management.
评论 #30079255 未加载
grncdr超过 3 年前
This looks like a really useful tool for staging and development environments, and it&#x27;s even OSS that can be self-hosted! Does anybody here have any real-life experiences with it they could to share?
评论 #30083880 未加载
评论 #30071054 未加载
评论 #30071550 未加载
madjam002超过 3 年前
I&#x27;m doing something similar by cloning the data directory using BTRFS snapshots for backups and testing, apart from the UI is there a reason why this tool might be worth looking at?
Dowwie超过 3 年前
I just came across testcontainers this week, which seems to solve similar problems. Has anyone tried both solutions and can comment about their experiences with them?
评论 #30073076 未加载
text2db超过 3 年前
A little off topic, but you can convert simple text to PostgreSql scripts,<p><a href="https:&#x2F;&#x2F;text2db.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;text2db.com&#x2F;</a>
评论 #30070201 未加载
jaxn超过 3 年前
Is this advocating the use of production data in dev&#x2F;test&#x2F;qa environments?<p>I am struggling to come up with scenarios where that would be a good idea.
评论 #30070546 未加载
评论 #30070482 未加载
评论 #30070426 未加载
评论 #30071639 未加载
评论 #30070293 未加载