ProdSens.live

Friday, 4 December 2026Eight desks, updated through the day

How NonoDB Document History Reconstructs a 2 a.m. Pricing Incident

A NonoDB incident example shows how immutable document revisions can connect a pricing failure to earlier configuration and product changes—while exposing the limits of retention and global ordering.

How NonoDB Document History Reconstructs a 2 a.m. Pricing Incident — illustration

Key takeaways

  • NonoDB history stores immutable revisions for document writes alongside the current document.

  • The example links a pricing change to a preceding VAT-mode update, but the suspected cause remains an interpretation rather than proof.

  • Global revision numbers help correlate commits but do not provide a whole-database historical snapshot.

  • History must be enabled in advance, and pruning can make older investigations dependent on backups.

At 02:14, the checkout total for every EU customer falls by 19%. Seventeen minutes later, support has received three refund requests, but the available logs, dashboards and current database values cannot establish what the price was before the incident, what changed, or whether a rollback removed only the affected changes.

The NonoDB example presents document versioning as a way to investigate that gap. When history is enabled for a collection, each insert, update and delete is stored as an immutable revision alongside the current document, within the same transaction. A revision can include the operation, timestamp, deletion status and a complete document snapshot.

From an unexplained update to a sequence

In the example, history is enabled for the products and config collections with retention set to 100. The sample retrieves revisions for sku_1042, newest first, and can request an individual version with products.get_version("sku_1042", 91233). If pruning has already removed that revision, the lookup returns None.

A revision comparison identifies an update at 02:14:07 that changes the product price from 12900 to 10449 and sets tax_rate from 0.19 to 0.00. The source treats the tax change as evidence that this was not an ordinary price edit. It may indicate that a configuration value reached the wrong field or that a migration used an incorrect mapping, but the version record itself does not prove that interpretation.

Looking across selected documents adds more context. The example timeline places config/pricing changing vat_mode from inclusive to exclusive at revision 91870 and 02:13:52. It then shows tax_rate changing to zero on sku_1042 and sku_1043 at revision 91877 and 91878, followed by sku_1050 at revision 91879 and 02:14:08. This supports a timeline in which a configuration change preceded a writer applying the new mode incorrectly.

Useful ordering, limited reconstruction

The global rev value gives the daemon’s commit order for the revisions being examined. It is useful for correlating events, but it is not a database-wide point-in-time marker: unrelated writes can be interleaved, and NonoDB has no find_as_of(rev) operation. Individual documents can be recovered by walking their revisions, but the system is not a temporal database.

History also has operational limits. It is not backfilled, so a collection begins recording past changes only after history is enabled and a later write occurs. Retention is set per collection and counts revisions per document, rather than days. A value of 0 disables new history writes, while changes to retention are applied by a background pruning job. Once an older revision has been pruned, investigation returns to backups, which provide snapshots rather than a change timeline.

Finding the wider impact

For blast-radius analysis, the example first queries a writer-maintained field such as updated_at from the incident start time, projects document IDs and limits the candidate set to 5,000 results. History can then be retrieved for each candidate. That approach combines an application-level filter with immutable revisions, rather than assuming that a global revision number identifies every affected document.

Why it matters for your role

Pick the building you work in.

For software engineers

Document-level revisions can preserve the old and new values that ordinary update logs may omit. Engineers can use revision order to correlate configuration and product changes, while avoiding claims that it represents a complete database snapshot.

For QA engineers

The recorded snapshots and field-level differences provide evidence for checking whether a configuration change affected multiple product documents. Retention and the lack of backfill make history configuration part of incident-readiness planning.

For project managers

A revision timeline can give an incident ticket a concrete sequence of configuration and document updates. Teams still need to distinguish observed revisions from hypotheses about the writer’s behavior.

Based on reporting by DEV Community (source article).

Written with AI assistance and reviewed under our editorial standards. Spotted an error? Tell the desk.

Comments

Join the discussion

Your email address will not be published. Required fields are marked *

Follow the city on Telegram

Every new story from all eight desks, as it lands. No inbox, no sign-up form, just open the channel and read.

@prodsens

Product, project, software, QA, AI, analytics, marketing and planning news in one feed.

Open in Telegram (opens in a new tab)