prop/rust/prop_grid_rs
Graham McIntire 95976b6b90
Some checks failed
Build prop-grid-rs / Test, build, push (push) Successful in 5m3s
Build and Push / Build and Push Docker Image (push) Failing after 5m57s
perf(grid-rs): drop legacy .mp.gz write, parallelize decodes, overlap fetch+decode, cap retries
Four optimisations targeting the 11.4s chain-step critical path:

1. Drop legacy .mp.gz dual-write (~2.5-2.8s, 24% of step)
   The Elixir reader prefers .sgrid; the chunked gzip+msgpack write was
   pure overhead on the Rust write path. Removed scalar_future from both
   run_chain_step and run_analysis_step.

2. Parallelize wgrib2 decodes (~0.5-1s)
   sfc and prs decode ran serially (await sfc, then await prs). Both now
   spawn concurrently on the blocking pool.

3. Overlap sfc decode with prs fetch (~1-2s)
   sfc (9 messages) resolves before prs (39 messages). Start the sfc
   wgrib2 subprocess as soon as the sfc blob lands instead of waiting
   for both blobs. The sfc decode hides behind the remaining prs fetch.

4. Cap grib range retries from 5 to 3
   2^n exponential backoff meant 1+2+4+8+16 = 31s worst-case per failed
   range. Three retries caps at 1+2+4 = 7s. 404s already fail fast.

Also: instrument .sgrid write (observe_stage) so it appears in the
prop_grid_rs_stage_duration_seconds histogram alongside fetch/decode/derive.

Expected mean chain step: ~6-7s (down from 11.4s).
2026-08-01 12:48:01 -05:00
..
src perf(grid-rs): drop legacy .mp.gz write, parallelize decodes, overlap fetch+decode, cap retries 2026-08-01 12:48:01 -05:00
tests perf(grid-rs): dense grid, fused scoring pass, and columnar .pgrid profiles 2026-08-01 08:23:36 -05:00
.gitignore feat(grid-rs): Rust worker for HRRR f01..f18 propagation chain 2026-04-19 15:42:49 -05:00
Cargo.lock chore: update all dependencies, fix Bandit CVE-2026-65623 HIGH 2026-07-27 11:35:06 -05:00
Cargo.toml chore(rust): trim unused crate features 2026-04-24 12:25:10 -05:00
Dockerfile perf(grid-rs): cargo-chef + unified --release profile in CI build 2026-04-30 09:54:25 -05:00