forked from ManageIQ/manageiq
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request ManageIQ#14023 from Ladas/scanning_for_used_attrib…
…utes_for_query_optimizations Scanning for used attributes for query optimizations
- Loading branch information
Showing
6 changed files
with
535 additions
and
113 deletions.
There are no files selected for viewing
12 changes: 12 additions & 0 deletions
12
app/models/manager_refresh/application_record_reference.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
module ManagerRefresh | ||
class ApplicationRecordReference | ||
attr_reader :base_class_name, :id | ||
|
||
# ApplicationRecord is very bloaty in memory, so this class server for storing base_class and primary key | ||
# of the ApplicationRecord, which is just enough for filling up relationships | ||
def initialize(base_class_name, id) | ||
@base_class_name = base_class_name | ||
@id = id | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.