frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Sometimes, the quiet achievements are the most important ones

https://herbertlui.net/sometimes-the-quiet-achievements-are-the-most-important-ones/
1•herbertl•5m ago•0 comments

Ask HN: Change my mind) should AI coding conversations be append-only?

1•wsxiaoys•6m ago•0 comments

Oracle stock on pace for worst quarter since 2001, AI concerns

https://www.cnbc.com/2025/12/26/oracle-stock-on-pace-for-worst-quarter-since-2001-ai-concerns.html
2•speckx•7m ago•0 comments

The Secret Service Agent Haunted by His Failure to Save JFK

https://www.nytimes.com/interactive/2025/12/16/magazine/clint-hill-jfk-secret-service.html
1•bookofjoe•9m ago•1 comments

Cursed circuits #4: PLL frequency multiplier

https://lcamtuf.substack.com/p/cursed-circuits-4-pll-frequency-multiplier
2•ArmageddonIt•14m ago•0 comments

Show HN: A small embeddable and hackable Lisp-2 interpreter in C

https://github.com/mistivia/bamboo-lisp
2•mistivia•16m ago•0 comments

Elevator Wiki: wiki about elevators and their related topics

https://elevation.fandom.com/wiki/Elevator_Wiki
2•thunderbong•18m ago•0 comments

Star Guage

https://en.wikipedia.org/wiki/Star_Gauge
1•nz•18m ago•0 comments

Resolve merge conflicts with Claude Code

https://raine.dev/blog/resolve-conflicts-with-claude/
1•rane•18m ago•0 comments

Tixl: Open-source realtime motion graphics

https://github.com/tixl3d/tixl
1•nateb2022•19m ago•0 comments

Show HN: An authority gate for AI-generated customer communication

https://authority.bhaviavelayudhan.com
2•bhaviav100•21m ago•2 comments

MongoBleed

https://github.com/joe-desimone/mongobleed/blob/main/mongobleed.py
2•gpi•22m ago•0 comments

Gh-yule-log: GitHubCLI extension turns your terminal into an animated Yule log

https://github.com/leereilly/gh-yule-log
1•nateb2022•22m ago•0 comments

BitVault – A time-delayed multisig Wallet Solution delivering utmost security

https://www.bitvault.sv/
1•bitvaulty•27m ago•1 comments

The Louvre museum's collection database, updated daily

https://collections.louvre.fr/en/
2•Fiveplus•27m ago•0 comments

Show HN: StegCore – a decision boundary for AI systems (truth ≠ permission)

https://github.com/StegVerse-Labs/StegCore
1•the_rige1•28m ago•0 comments

Ask HN: How to gain a solid understanding of IMUs?

1•feefifoflux•33m ago•0 comments

The AI Reality Check: Deconstructing the 2025 Stack Overflow Developer Survey

https://nitinahirwal.in/posts/Stack-Overflow-Survey-2025
3•foobuzzHN•35m ago•1 comments

Vanslist – No middlemen. No fees. Just people

https://vanslist.com/
1•netgeniuskid•35m ago•0 comments

Do you believe in society's lies?

https://samkriss.substack.com/p/do-you-believe-in-societys-lies
2•paulpauper•35m ago•1 comments

Why Everyone Loves Japan

https://www.noahpinion.blog/p/why-everyone-loves-japan
2•paulpauper•36m ago•0 comments

The 2m Peak

https://writingcosmo.substack.com/p/the-2m-peak
1•tsterin•37m ago•0 comments

The Misfit Tree

https://collabfund.com/blog/the-misfit-tree/
1•herbertl•37m ago•0 comments

Leaker Who Apple Is Suing Says 'Screw It,' Here's the Foldable iPhone Early

https://gizmodo.com/leaker-who-apple-is-suing-says-screw-it-heres-the-foldable-iphone-early-20007...
2•achow•38m ago•0 comments

I Killed Color on My Phone. The Result Shocked Me

https://www.nytimes.com/2025/12/25/opinion/smartphone-color-grayscale-addiction.html
5•mikhael•38m ago•1 comments

Konami Code

https://craigatallahfrost.com/post/2025/12/23/konami-code
1•herbertl•41m ago•0 comments

Laid Off After 25 Years in Tech [video]

https://www.youtube.com/watch?v=VeMA9WGKxOg
3•akhilnchauhan•41m ago•0 comments

Affiliarena Kickstart Challenge – Mehr Verdienen ALS Online Marketer

https://simon-veith.net/jetzt-geht-es-los-mit-der-ki-revolution/affiliarena-kickstart-challenge-m...
1•hellocosmetics•42m ago•0 comments

Chess960v2 – the first championship has officially started

https://chess960v2.com/en
1•lavren1974•42m ago•0 comments

Metastable Failures and Interactions Between Systems

https://charap.co/on-metastable-failures-and-interactions-between-systems/
2•todsacerdoti•43m ago•0 comments
Open in hackernews

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

1•LawZiL•7mo 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•7mo 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•7mo 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•7mo 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•7mo ago
Load test against a clone instead of a DB whose contents you care about?