cascade
cascade copied to clipboard
Optimize computed values derived from the configuration
There are a number of places where information inside the configuration is used to compute some expensive(?) result. The result must be constantly recomputed in case the configuration changes between executions.
Instead, a mechanism to link the calculation to the configuration such that the value is lazily computed, and invalidated when the configuration changes. This could be built on top of the watcher mechanism for atoms (watching @configuration for changes) and another atom to store the lazily computed value (resetting it to nil when the configuration is changed).
This has become a lot less necessary because the configuration is not used nearly as much now as it was in earlier versions of the framework.