Skip to content

Commit

Permalink
Merge pull request #151 from jrafanie/drop_require_nested_include_con…
Browse files Browse the repository at this point in the history
…cern

Drop require_nested and include_concern
  • Loading branch information
agrare authored Feb 6, 2024
2 parents b94f5ba + cd09882 commit a212809
Show file tree
Hide file tree
Showing 10 changed files with 3 additions and 37 deletions.
20 changes: 0 additions & 20 deletions app/models/manageiq/providers/ibm_power_hmc/infra_manager.rb
Original file line number Diff line number Diff line change
@@ -1,24 +1,4 @@
class ManageIQ::Providers::IbmPowerHmc::InfraManager < ManageIQ::Providers::InfraManager
require_nested :EventCatcher
require_nested :EventParser
require_nested :EventTargetParser
require_nested :Host
require_nested :MetricsCapture
require_nested :MetricsCollectorWorker
require_nested :Provision
require_nested :ProvisionWorkflow
require_nested :Refresher
require_nested :RefreshWorker
require_nested :Template
require_nested :Vm
require_nested :Lpar
require_nested :Vios
require_nested :Storage
require_nested :ResourcePool
require_nested :MemoryResourcePool
require_nested :ProcessorResourcePool
require_nested :MediaRepository

supports :catalog
supports :create
supports :metrics
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
class ManageIQ::Providers::IbmPowerHmc::InfraManager::EventCatcher < ManageIQ::Providers::BaseManager::EventCatcher
require_nested :Runner
end
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
class ManageIQ::Providers::IbmPowerHmc::InfraManager::MetricsCollectorWorker < ManageIQ::Providers::BaseManager::MetricsCollectorWorker
require_nested :Runner

self.default_queue_name = "ibm_power_hmc"

def friendly_name
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
class ManageIQ::Providers::IbmPowerHmc::InfraManager::Provision < MiqProvision
include_concern 'Cloning'
include_concern 'StateMachine'
include Cloning
include StateMachine

VALID_REQUEST_TYPES = %w[clone_to_template template].freeze
validates :request_type, :inclusion => {:in => VALID_REQUEST_TYPES, :message => "should be one of: #{VALID_REQUEST_TYPES.join(', ')}"}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
class ManageIQ::Providers::IbmPowerHmc::InfraManager::RefreshWorker < MiqEmsRefreshWorker
require_nested :Runner
end
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
class ManageIQ::Providers::IbmPowerHmc::InfraManager::Vm < ManageIQ::Providers::InfraManager::Vm
include ManageIQ::Providers::IbmPowerHmc::InfraManager::MetricsCaptureMixin

include_concern "Reconfigure"
include Reconfigure

virtual_delegate :hmc_managed, :to => :host, :prefix => true, :allow_nil => true, :type => :boolean

Expand Down
3 changes: 0 additions & 3 deletions app/models/manageiq/providers/ibm_power_hmc/inventory.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,2 @@
class ManageIQ::Providers::IbmPowerHmc::Inventory < ManageIQ::Providers::Inventory
require_nested :Collector
require_nested :Parser
require_nested :Persister
end
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
class ManageIQ::Providers::IbmPowerHmc::Inventory::Collector < ManageIQ::Providers::Inventory::Collector
require_nested :InfraManager
require_nested :TargetCollection
end
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
class ManageIQ::Providers::IbmPowerHmc::Inventory::Parser < ManageIQ::Providers::Inventory::Parser
require_nested :InfraManager
require_nested :TargetCollection
end
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
class ManageIQ::Providers::IbmPowerHmc::Inventory::Persister < ManageIQ::Providers::Inventory::Persister
require_nested :InfraManager
require_nested :TargetCollection
end

0 comments on commit a212809

Please sign in to comment.