-
- Downloads
Prebake common history queries (#37496)
* Prebake common history queries The python overhead of to construct the queries exceeded the database overhead. We now prebake the queries that get frequently polled. This reduces the time it takes to update history_stats sensors and can make quite a difference if there are a lot of them. When using the mini-graph-card card, all the entities on the card being graphed are queried every few seconds for new states. Previously this would tie up the database if there are lot of these graphs in the UI. * Update homeassistant/components/history/__init__.py Co-authored-by:Paulus Schoutsen <paulus@home-assistant.io> * Update homeassistant/components/history/__init__.py Co-authored-by:
Paulus Schoutsen <paulus@home-assistant.io> * cache entity_filter in the lambda * switch to yield * Revert "switch to yield" This reverts commit f8386f494002178729b67b54dd299affd406f2f2. * get_states always returns a list * query wasnt actually reusable so revert part of the breakout Co-authored-by:
Paulus Schoutsen <paulus@home-assistant.io>
Loading
Please register or sign in to comment