You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If DI/1 (or any other bean factory) is managing the controllers, FW/1 should not cache them, so that just reloading the bean factory will be sufficient to reload the controllers.
The text was updated successfully, but these errors were encountered:
This is slightly harder than it first looks. If we don't cache the controllers (even from a bean factory) then every access to a controller will take a performance hit (even just looking up beans in a factory can be non-trivial as well as the two structKeyExists() calls and the exclusive lock).
The solution I'm adopting is to flush the FW/1 controller cache whenever the bean factory is set. This should provide the best of both worlds: the fastest possible controller access (as now) with the reloading of controllers (whether managed or not) whenever the bean factory is set.
While I was in there, I observed that getCachedComponent() is only used for controllers now that services are not managed by FW/1 so I was able to simplify the code (removing all the type / types stuff) and that improved the speed a bit! Win!
If DI/1 (or any other bean factory) is managing the controllers, FW/1 should not cache them, so that just reloading the bean factory will be sufficient to reload the controllers.
The text was updated successfully, but these errors were encountered: