case · no. 04Fintech · logistics · Series Cshipped 04·12·2026 · 42 engineering days
Meridian Logistics

Rebuilding a nine-year-old pricing engine — in six weeks.

A monolith carrying every SKU, promo, tax rule, and ledger entry since 2017. Pricing had become the blocker on every launch. We carved it into four services, migrated 42 TB of history, and cut p95 by 74% — without a single minute of downtime.

rails → gostranglerk8skafkazero-downtime42 tb migration
We rebuilt their pricing engine in six weeks. P95 dropped 38% before the full cutover — the remaining 36% came from killing the monolith's write-amplification on day 42. The team stayed on-call with us through Q2 earnings.
principal engLogic Layer
01The situation · Q1 2026

Every pricing change required a two-hour deploy.

Meridian's pricing system — born in 2017 as a single Rails app — had swallowed catalog, discounts, tax, fraud checks, and the ledger. Eighty-four engineers touched it. Launches were blocked behind a pricing squad that couldn't ship faster than one change per day.

Three previous modernization attempts had stalled at the foreign-key diagram stage. We were hired for the fourth — on the explicit condition that the first artefact would be a shipping cutover, not a slide deck.

02Architecture · before → after

One box became four services and a gateway.

before · 2017 → 2025
rails · single pg · 2h deploys · shared schema
PRICING-MONOLITH (2017)catalogpricingdiscountstaxledgerfraudaudit
after · 04·12·2026
go · k8s · kafka · typed contracts · 94s deploys
API GATEWAY · RATE · AUTHpricingGO · K8SdiscountGO · K8StaxGO · K8SfraudGO · K8SEVENTS · KAFKAPG · READ REPLICASREDIS · HOT CACHE
03Approach — strangler, not rewrite

We never paused the monolith. We slowly starved it.

A gateway in front of pricing traffic forked requests to the new services in shadow mode. We ran parity for three weeks — every response double-computed, diffed, logged. The day parity passed 99.99%, we flipped the flag.

  1. w 01Discover · trace 2 weeks of production pricing calls
  2. w 02Design · event contracts, read-model, cutover plan
  3. w 03–04Build · four services + gateway, shadow mode
  4. w 05Parity · 99.998% match, 2 rounding deltas fixed
  5. w 06Cutover · ramp 10 → 50 → 100, rollback armed 72h
  6. w 07+Operate · on-call with Meridian SRE, weekly tuning
Deploy log · cutover night
cutover · 04·12·2026 · 02:47 UTCzero-downtime
02:47:01shadow-traffic 100% · 30min
03:17:02parity: 99.998% (2 rounding delta, expected)
03:17:14flip gateway: 10% → pricing-v2
03:22:00p95 448ms · err 0.004%
03:37:00ramp: 50% → pricing-v2
03:52:00ramp: 100% → pricing-v2
03:52:45·monolith read-only · ledger quiesced
03:55:12cutover complete · rollback armed 72h
04Outcome · 30 days post-cutover

P95 dropped 38% before cutover. The other 36% came on day 42.

Shadow-mode alone — fewer JOIN fanouts on reads — cut p95 by 38%. The remaining gain came after we killed the monolith's write-amplification pattern, which was cascading through three async jobs per order.

p95 latency · last 10 weeks
500100015002000BEFORE · 1.72s P95AFTER · 450ms P95
latency p95
450ms
−74% · from 1.72s
infra cost
$58k/mo
−68% · from $184k
deploy time
94s
−99% · from 2h 40m
incidents
0
30-day post-cutover
05 · The team

Four engineers. One principal on-call from day one through Q2 earnings.

  • Priya K.
    Principal engineer · architecture
    Tokyo · GMT+9
  • Jonas T.
    Senior backend · pricing + discount svc
    Berlin · GMT+1
  • Renata M.
    Senior backend · tax + fraud svc
    São Paulo · GMT−3
  • Andrés V.
    SRE · gateway, rollout, on-call
    Mexico City · GMT−6
end · want one of these?

If your monolith is the blocker, we'll read the code first.

canonical