prop/test/microwaveprop_web
Graham McIntire a14f14485e
perf(weather): serve /weather from chunked scalar artifacts
Move the /weather render path off raw HRRR profile decoding + per-cell
SoundingParams + WeatherLayers derivation. The dominant cost was
re-deriving the same scalar fields on every viewport pan and timeline
scrub.

Server side:

- New Microwaveprop.Weather.ScalarFile persists pre-derived scalar
  rows on NFS, bucketed into 5°×5° chunk files under
  <base>/weather_scalars/<iso>/<lat_band>_<lon_band>.etf.gz. Viewport
  reads only decode the chunks that overlap the requested bounds;
  point-detail clicks read exactly one chunk.
- weather_grid_at/2 and weather_point_detail/3 prefer ScalarFile;
  ProfilesFile is now the cold-start fallback only.
- warm_grid_cache_and_broadcast/1 and warm_grid_cache_from_latest_profile/0
  also persist the scalar artifact, and the cold-derive path kicks
  off a per-valid_time-locked async materialization so the next
  reader gets the cheap path.
- NotifyListener.handle_propagation_ready/1 fires
  Weather.materialize_scalar_file/1 in a detached Task on the Rust
  pipeline's NOTIFY propagation_ready, so steady-state forecast hours
  arrive with their scalar artifact already on disk.
- available_weather_valid_times/0 unions ScalarFile + ProfilesFile so
  the timeline survives an aggressive retention sweep on either side.

Browser side (finding #8):

- Mount the legend Leaflet control once and patch its inner content
  on layer changes instead of remove + re-add on every renderLayer.
- renderTimeline now keys off the rendered button set: selection-only
  updates take an applyTimelineSelection patch path that restyles
  existing buttons in place. Full innerHTML rebuild only fires when
  timelineData itself changes.

Also fixes a credo nesting-depth flag in tile_renderer.ex by extracting
interpolate_pair/2 from the inner anonymous function.
2026-04-28 17:15:36 -05:00
..
controllers perf(weather): serve /weather from chunked scalar artifacts 2026-04-28 17:15:36 -05:00
live perf(weather): serve /weather from chunked scalar artifacts 2026-04-28 17:15:36 -05:00
plugs fix(remote_ip): log IPv6 in canonical hex via :inet.ntoa 2026-04-25 18:05:46 -05:00
analytics_test.exs feat: harden /map analysis breakdown + move Plausible to root layout 2026-04-21 15:56:30 -05:00
live_helpers_test.exs refactor: deduplicate helpers and simplify Scorer 2026-04-28 14:14:34 -05:00
live_table_footer_test.exs Show windowed page list in live_table footer 2026-04-13 10:02:19 -05:00
location_resolver_test.exs refactor: deduplicate helpers and simplify Scorer 2026-04-28 14:14:34 -05:00
metrics_log_suppression_test.exs fix(web): suppress HEAD request logs 2026-04-22 16:50:58 -05:00
metrics_plug_test.exs test: push line coverage from 71.7% → 78.67% 2026-04-23 18:43:18 -05:00
skew_t_property_test.exs test(property): add property tests for terrain + atmospheric math 2026-04-21 13:56:39 -05:00
skew_t_test.exs Fix credo warnings: length/1 on list and nested module aliases 2026-04-16 08:49:25 -05:00
telemetry_test.exs test: fix async-hydration timeout flake + type warning 2026-04-24 09:28:52 -05:00
user_auth_test.exs Beacon power in mW, settings tweaks 2026-04-08 12:45:35 -05:00