Single-binary self-hosted market watcher for stocks, ETFs, indexes, and futures: live charts, key stats, fundamentals, SEC filings, and SSE streaming.
axumdockerfinancerustself-hostedsqlitestocksvite
1-- finance migration 0003: record each endpoint guard's per-hour request
2-- budget in its own row (Phase 6).
3--
4-- The budget is a property of how each `EndpointGuard` is constructed
5-- (`EndpointGuard::new` uses 200; the Yahoo guard uses 1000). Persisting it
6-- lets the data-health page show "requests used / budget" straight from the
7-- table, with no upstream-specific constant duplicated into the route layer.
8-- `EndpointGuard::load` keeps this column in step with the guard's own budget.
9--
10-- The DEFAULT covers the rows that already exist (the guard corrects each one
11-- to its true budget the next time that endpoint is used).
12
13ALTER TABLE endpoint_guard ADD COLUMN hourly_budget INTEGER NOT NULL DEFAULT 200;