No description
Find a file
Graham McIntire b984794571
Hoist commercial link query + tie pipeline chip to ScoresFile
PropagationGridWorker.merge_commercial_link_data/2 called
Commercial.link_degradation_at twice per grid cell (once to count,
once to merge), and each call re-ran enabled_links plus two sample
queries per in-range link. That was ~500k SQL queries per forecast
hour — fine for the DB but catastrophic for log volume in dev
iex sessions trying to watch a chain step run.

Split into two new functions:
  * build_link_lookup/2 does all the DB work up front — one
    enabled_links query + one link_degradation per enabled link
    (~10 queries total).
  * link_degradation_from_lookup/3 is pure: takes a (lat, lon)
    and the precomputed lookup, returns the aggregate or nil.

The worker now calls build_link_lookup once per forecast hour and
the per-cell path is haversine-only. Net: 500k queries → ~10.

PipelineStatus freshness detection moves off oban_jobs.completed_at
onto ScoresFile.latest_valid_time(). The on-disk files ARE the data
the map renders from, so the chip's "Up to date · Nm ago" and the
2h stale threshold now track actual data presence. Running-state
detection still comes from oban_jobs since the chain step is still
an Oban row. Tests updated to seed a ScoresFile instead of a
completed Oban row for the idle/stale cases.
2026-04-14 15:01:12 -05:00
.forgejo/workflows Install Docker CLI in CI runner container 2026-04-11 09:04:22 -05:00
.github Add contact edit approval system with admin review queue 2026-04-11 16:15:49 -05:00
assets Add grid squares and weather radar toggles to the weather map 2026-04-13 16:31:54 -05:00
bin Fix livebook path resolution in bin/notebook 2026-04-07 11:15:49 -05:00
config Flip map read path to ScoresFile, stop writing grid HRRR profiles 2026-04-14 14:50:43 -05:00
docs Move NFS share from skippy to node3 at 10.0.15.103:/data 2026-04-14 14:25:42 -05:00
k8s Merge remote-tracking branch 'origin/main' 2026-04-14 14:25:50 -05:00
lib Hoist commercial link query + tie pipeline chip to ScoresFile 2026-04-14 15:01:12 -05:00
lib_ml Retrain propagation ML on month-balanced HRRR → algorithm score 2026-04-14 08:16:08 -05:00
notebooks Auto-deploy analysis notebook as Livebook app 2026-04-07 11:15:49 -05:00
priv Cut propagation_scores write cost with DELETE+COPY, skip-factors, UNLOGGED 2026-04-14 13:47:35 -05:00
rel Add Erlang clustering via libcluster and expose LiveDashboard 2026-04-06 09:46:48 -05:00
scripts Extend recalibrate_algo.py with NEXRAD, native-duct, commercial sections 2026-04-13 12:14:05 -05:00
test Hoist commercial link query + tie pipeline chip to ScoresFile 2026-04-14 15:01:12 -05:00
vendor Vendor oban_pro 1.6.13 2026-04-09 14:14:49 -05:00
.credo.exs credo 2026-04-12 10:26:53 -05:00
.dockerignore Optimize Dockerfile layer caching 2026-04-01 10:32:56 -05:00
.formatter.exs initial 2026-03-28 11:28:47 -05:00
.gitignore Dual-write propagation scores to binary files on /data 2026-04-14 14:36:55 -05:00
.tool-versions update deps 2026-04-11 12:03:43 -05:00
AGENTS.md initial 2026-03-28 11:28:47 -05:00
algo.md Wire NEXRAD, native ducts, and commercial links into scoring 2026-04-13 12:08:15 -05:00
app.json Migrate healthchecks from CHECKS to app.json 2026-04-04 11:24:56 -05:00
CLAUDE.md Move NFS share from skippy to node3 at 10.0.15.103:/data 2026-04-14 14:25:42 -05:00
Dockerfile Use NCEPLIBS-g2c v2.1.0 + enable wgrib2 PNG decoder 2026-04-14 11:06:04 -05:00
elevation.md add elevation findings 2026-03-29 16:23:03 -05:00
mix.exs Unblock CI: pull igniter into :prod for live_table compile 2026-04-12 17:58:13 -05:00
mix.lock Add live_table dep and convert /users to use it 2026-04-12 17:07:07 -05:00
prediction.md HRRR forecast hours (f00-f18) with timeline map UI 2026-03-31 16:44:47 -05:00
README.md initial 2026-03-28 11:28:47 -05:00
tail_logs.sh Add type filter to backfill enqueue 2026-04-06 11:42:26 -05:00
updates.md Update seasonal scores from sounding data, document commercial link patterns 2026-04-07 11:45:44 -05:00

Microwaveprop

To start your Phoenix server:

  • Run mix setup to install and setup dependencies
  • Start Phoenix endpoint with mix phx.server or inside IEx with iex -S mix phx.server

Now you can visit localhost:4000 from your browser.

Ready to run in production? Please check our deployment guides.

Learn more