Speeds up "VMs & Instances I Own" index and ajax calls in the /vm_or_template (Services -> Workload) section of the application. Followup to #10290 and alternative to #10525 This is more similar to the #10290 approach. Further PRs will leverage virtual_delegates. @NickLaMuro found where to optimize, wrote up the description, an was gracious enough to let me throw my hat into the ring. How This adds virtual_attribute on to the ownership_mixin, which is used by a few classes and makes it so that MiqExpressions will evaluate filter in SQL instead of pulling down all matching records to then iterate over and filter in Ruby (causes a Massive N+1 on large datasets).
https://github.com/ManageIQ/manageiq/pull/10704
This BZ talks about PR 10704 which was implemented within the same context as PR 10685 (as per my discussion with ui perf dev team) ..and the corresponding BZ https://bugzilla.redhat.com/show_bug.cgi?id=1375346 has been verified. That said, pasting the numbers from #1375346 for reference: Quantifier Data: { "pages": { "vm_or_template/explorer": { "navigations": 6, "200": 6, "timings": [ { "200": 9.11 }, { "200": 1.67 }, { "200": 2.75 }, { "200": 2.01 }, { "200": 1.15 }, { "200": 1.8 } ] } }, "number of requests": 6 } an explicit test using curl against the POST route for the filter is not straight-forward at the moment, but the improvements from the fix have been confirmed by the team.