towerops/priv/repo/migrations/20260306234425_add_capacity_fields_to_interfaces.exs
Graham McIntire 3913981094
feat: add backhaul capacity analysis foundation
Add per-interface capacity tracking with manual override and automatic
detection from SNMP sensors. Includes capacity resolver with priority
cascade (manual > sensor > if_speed), throughput calculation from
interface stats, and site/organization-level capacity summaries.

- Migration: add configured_capacity_bps and capacity_source to snmp_interfaces
- Capacity.Resolver: multi-source capacity detection with vendor unit normalization
- Capacity context: throughput calculation, utilization percentages, site/org summaries
- Snmp context: set_manual_capacity/2 and clear_manual_capacity/1 functions
2026-03-06 17:54:32 -06:00

10 lines
241 B
Elixir

defmodule Towerops.Repo.Migrations.AddCapacityFieldsToInterfaces do
use Ecto.Migration
def change do
alter table(:snmp_interfaces) do
add :configured_capacity_bps, :bigint
add :capacity_source, :string
end
end
end