frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

We Need to Quarantine Aliens on the Moon, Scientists Propose

https://www.404media.co/we-need-to-quarantine-aliens-on-the-moon-scientists-propose/
1•Brajeshwar•1m ago•0 comments

Do Language Models Flatten Your Business? We Tested Four Real Ones to Find Out

https://industrycontents.com/language-models-flatten-brand-positioning/
1•ticust•2m ago•0 comments

Pgtestdb's template cloning approach to testing is fast

https://brandur.org/fragments/pgtestdb
3•brandur•3m ago•0 comments

BMW Is Showing Commercials on Their Car's Dash Screens as a Treat

https://www.theautopian.com/bmw-is-showing-commercials-on-their-cars-dash-screens-and-they-want-y...
2•CharlesW•6m ago•2 comments

Scope of Hacks on U.S. Water Supply Widens as Evidence Points to Iran

https://www.nytimes.com/2026/08/01/us/politics/iran-cyberattack-water-systems.html
4•jbegley•7m ago•0 comments

Leaked Document Names Mainstream Journalists Taking Pay-for-Play Trips to China

https://nataliegwinters.substack.com/p/exc-leaked-document-names-mainstream
3•sleepyguy•8m ago•0 comments

Disabling Blocking on Dual Pi-Hole DNS Servers with a Shell Script

https://justinribeiro.com/chronicle/2026/07/30/disabling-blocking-on-dual-pi-hole-dns-servers-wit...
2•speckx•8m ago•0 comments

Carl's Required Reading

https://carlkolon.com/reading/
3•cckolon•13m ago•0 comments

US Military F-35B fighter jet crashes and burns at California Marine Corps base

https://www.cnn.com/2026/07/31/us/military-jet-crash-california-marine-base
2•teleforce•17m ago•0 comments

Kenji/Serious Eats – 30-Min Pressure Cooker Pho Ga

https://www.seriouseats.com/30-minute-pressure-cooker-pho-ga-recipe
3•stasomatic•17m ago•1 comments

Crystal Wars – turn-based strategy on a fresh Voronoi map every match

https://play.crystalwars.io
3•VertexNoord•20m ago•1 comments

The Bedrock of Software Design

https://alex.draftist.io/blog/the-bedrock-of-software-design-ycqvcedsj
4•birdculture•20m ago•0 comments

The Absent Narrator

http://blog.funcall.org/ai/2026/07/31/absent-narrator/
2•varjag•21m ago•0 comments

Indexing the Data Lake for Online Point Queries

https://engineering.atspotify.com/2026/7/indexing-the-data-lake-for-online-point-queries
4•kalaracey•23m ago•0 comments

AI Adoption Is Dividing Friends, Families and Co-Workers

https://www.bloomberg.com/news/articles/2026-07-30/how-chatgpt-and-ai-are-dividing-friends-and-fa...
2•theanonymousone•25m ago•0 comments

GitHub has alternatives, but no replacement

https://lalitm.com/post/github-alternatives/
14•lalitmaganti•25m ago•4 comments

Show HN: Netmnt 0.2.0

https://github.com/thongor77/netmnt
2•magetriste•29m ago•0 comments

What Luxury Housing Does to Homelessness [video]

https://www.youtube.com/watch?v=rQW4W1_SJmc
2•felineflock•37m ago•0 comments

SupererDuperer

https://www.shirtpocket.com/blog/supererduperer
2•zdw•38m ago•0 comments

Cursor removed cost information from the usage page and CSV export

https://forum.cursor.com/t/usage-page-to-token-amount-what/167153
6•EugeneOZ•39m ago•0 comments

Explorative modeling: Train on the best of K guesses

https://alexiglad.github.io/blog/2026/explorative_modeling/
3•DSemba•41m ago•0 comments

The fall and rise of the English country house

https://www.english-heritage.org.uk/visit/inspire-me/the-fall-and-rise-of-the-english-country-house/
2•EndXA•42m ago•0 comments

Anthropic brags that its models committing crimes without being told to do so

https://www.cnbc.com/2026/07/30/anthropic-says-claude-gained-unauthorized-access-to-others-system...
3•zapataband1•42m ago•1 comments

PoE2 devs convinced Nvidia to fix a driver bug by sending it a PC

https://www.pcgamer.com/games/rpg/after-a-year-and-a-half-of-rigorous-testing-path-of-exile-2-dev...
3•exec•42m ago•0 comments

Token Reduction Is Not Cost Reduction

https://arxiv.org/abs/2607.12161
3•umitkaanusta•45m ago•1 comments

How to Stop Procrastinating

https://www.economist.com/science-and-technology/2026/07/31/how-to-stop-procrastinating
3•bookofjoe•47m ago•2 comments

CJEU Judgment on Knowledge of Foreign Copyright Laws and Geoblocking Measures

https://blog.ericgoldman.org/archives/2026/07/cjeu-judgment-on-geoblocking-standards-for-knowledg...
2•hn_acker•48m ago•1 comments

Toast IDE Gets Markdown Spell Checking

https://github.com/paradise-runner/toast
2•dividedcomet•48m ago•0 comments

Ask HN: Any tips for a college freshman enrolled in computer science?

3•NotParth11•49m ago•2 comments

The NUMBER – trusted number infrastructure

https://rounded.lol/
2•thunderbong•50m ago•0 comments
Open in hackernews

Ask HN: How can I load test PostgreSQL but avoid changing actual data?

1•LawZiL•1y ago
I'm running a load test on my Node.js application and want to simulate realistic write-heavy scenarios to stress test the system — especially the PostgreSQL database.

There's a part of the code that performs UPDATE queries, but during load testing, I don't want these updates to actually change the state of the database. However, I still want the database to experience the full impact of the update — query planning, locking, I/O, WAL writes, etc. — so I can measure how it affects performance under peak load.

Is there a best-practice approach to achieve this?

So far, the most viable option I’ve found is to wrap the UPDATE queries in a transaction and then roll it back — that way, the queries still execute, but the state doesn’t change. Is this the right way to go? Does rollback introduce any performance overhead that would skew my results? Are there better or more realistic alternatives that simulate the full write path without persisting changes?

Thanks in advance!

Comments

sargstuff•1y ago
pgbench[2] / pgreplay-go[0] / python locust[1]

very old school approach:

Misuse sql VIEW[3][4] to generate a temporary parallel table setup. Testing database separate from production database would be 'better', IMHO.

-----

[0] pgreplay-go : https://github.com/gocardless/pgreplay-go

[1] python locust : https://miguel-codes.medium.com/unconventional-load-testing-...

[2] pgbench load testing :

   a) https://medium.com/@c.ucanefe/pgbench-load-test-166bdfb5c75a

   b) https://neon.tech/blog/autoscaling-in-action-postgres-load-testing-with-pgbench

   c) https://hackernoon.com/how-to-create-and-load-test-data-in-postgresql-i41e353m
----------------------------

[3] : a) https://hashrocket.com/blog/posts/materialized-view-strategi...

      b) https://tech.jonathangardner.net/wiki/PostgreSQL/Materialized_Views

      c) https://stackoverflow.com/questions/77603705/what-is-the-use-of-materialized-view-in-postgresql
[4] : https://en.wikipedia.org/wiki/View_(SQL)
LawZiL•1y ago
but again, how can i perform the query, but not actually change the state, i really need the state to keep untouched, but be able to perform the query itself.
MatthiasPortzel•1y ago
> Does rollback introduce any performance overhead that would skew my results?

I would expect it to be the other way around—since the transactions are rolled back and not committed, they would have significantly less performance impact. But I’m working from an academic model of the database.

apothegm•1y ago
Load test against a clone instead of a DB whose contents you care about?