insights: minor finishing touches to make historical insights better
Created by: slimsag
This PR contains a few minor adjustments to make historical data generation for insights a bit nicer:
- Adds tuning knobs that we can adjust through the site configuration, e.g. to make historical data generation go faster in deployments where this is desirable.
- Caches
git.FirstEverCommit
and disables the historical insights enqueuer by default in dev environments, due to some complaints it uses a lot of resources (expected) and is annoying in dev environments. - Makes historical data generation 8x faster, by reducing precision: we now produce 1 data point per month for the last 6 months, instead of 1 data point per week for the last 52 weeks.
- Wipes existing DBs clean, to reduce confusion with the historical data generation timeframe change above.
Fixes #19089 (closed) Fixes #18961 (closed)