# Balance::StatsController#index

- **Period:** 13 May 18:37 UTC – 13 May 18:52 UTC
- **Throughput**: 0.2 / min
- **Average:** 101.3 ms

## Most Impactful Sections
| Kind | Location | Avg ms | Avg calls | Impact | Command |
| ---- | -------- | -----: | --------: | -----: | ------- |
| code | app/controllers/balance/stats_controller.rb:7 | 37.0 | 1.0 | 36.51% | `Balance::StatsController#index` |
| view | app/views/balance/stats/index.turbo_stream.slim | 28.0 | 1.0 | 27.63% |  |
| sql | app/models/summary.rb:59 | 7.33 | 1.0 | 7.24% | `SELECT gs.date FROM generate_series(?, ?, ?::interval) AS gs(date) LEFT JOIN su…` |
| sql | app/lib/sensor/query/helpers/sql/total.rb:173 | 5.67 | 1.0 | 5.59% | `WITH price_ranges AS ( SELECT name, starts_at, LEAD(starts_at, ?, ?::date) OVER…` |
| gc | ruby/gc.c | 8.0 | 0.67 | 5.26% | `GC.start` |
| redis | app/controllers/balance/stats_controller.rb:95 | 2.33 | 1.0 | 2.30% | `get` |
| sql | app/lib/sensor/summarizer.rb:123 | 6.0 | 0.33 | 1.97% | `INSERT INTO "summary_values" ("field","aggregation","value","date") VALUES (?, …` |
| redis | /usr/local/bundle/gems/activesupport-8.1.3/lib/active_support/cache/redis_cache_store.rb:464 | 2.0 | 1.0 | 1.97% | `pipeline` |
| cache | app/controllers/balance/stats_controller.rb:95 | 1.67 | 1.0 | 1.64% | `read` |
| sql | app/lib/sensor/summarizer.rb:36 | 4.0 | 0.33 | 1.32% | `COMMIT` |
| rack | /usr/local/bundle/gems/http_accept_language-2.1.1/lib/http_accept_language/middleware.rb:7 | 1.33 | 1.0 | 1.32% | `HttpAcceptLanguage::Middleware` |

[View on RoRvsWild ↗](https://www.rorvswild.com/applications/136101/requests/Balance::StatsController%23index?range=15m)