diff --git a/app/models/manageiq/providers/vmware/cloud_manager/refresh_parser.rb b/app/models/manageiq/providers/vmware/cloud_manager/refresh_parser.rb index 9343a7e19..934424215 100644 --- a/app/models/manageiq/providers/vmware/cloud_manager/refresh_parser.rb +++ b/app/models/manageiq/providers/vmware/cloud_manager/refresh_parser.rb @@ -143,6 +143,7 @@ def parse_vm(vm) :hostname => hostname, :location => uid, :vendor => "vmware", + :connection_state => "connected", :raw_power_state => status, :snapshots => [parse_snapshot(vm)].compact, :cpu_hot_add_enabled => cpu_hot_add, @@ -196,6 +197,7 @@ def parse_image(image, is_public) :name => name, :location => uid, :vendor => "vmware", + :connection_state => "connected", :raw_power_state => "never", :publicly_available => is_public } diff --git a/app/models/manageiq/providers/vmware/inventory/parser/cloud_manager.rb b/app/models/manageiq/providers/vmware/inventory/parser/cloud_manager.rb index bf9b0cbc8..acedb4214 100644 --- a/app/models/manageiq/providers/vmware/inventory/parser/cloud_manager.rb +++ b/app/models/manageiq/providers/vmware/inventory/parser/cloud_manager.rb @@ -35,6 +35,7 @@ def vms :hostname => vm[:hostname], :location => vm[:vm].id, :vendor => 'vmware', + :connection_state => "connected", :raw_power_state => vm[:vm].status, :orchestration_stack => persister.orchestration_stacks.lazy_find(vm[:vm].vapp_id), :snapshots => [], @@ -101,6 +102,7 @@ def images :name => image[:image].name, :location => image[:image].id, :vendor => 'vmware', + :connection_state => "connected", :raw_power_state => 'never', :publicly_available => image[:is_published] ) diff --git a/spec/models/manageiq/providers/vmware/cloud_manager/refresher_spec.rb b/spec/models/manageiq/providers/vmware/cloud_manager/refresher_spec.rb index 5f960abf0..21db0ac9c 100644 --- a/spec/models/manageiq/providers/vmware/cloud_manager/refresher_spec.rb +++ b/spec/models/manageiq/providers/vmware/cloud_manager/refresher_spec.rb @@ -176,7 +176,7 @@ def assert_specific_template :tools_status => nil, :boot_time => nil, :standby_action => nil, - :connection_state => nil, + :connection_state => "connected", :cpu_affinity => nil, :memory_reserve => nil, :memory_reserve_expand => nil, @@ -209,7 +209,7 @@ def assert_specific_vm_powered_on :tools_status => nil, :boot_time => nil, :standby_action => nil, - :connection_state => nil, + :connection_state => "connected", :cpu_affinity => nil, :memory_reserve => nil, :memory_reserve_expand => nil, @@ -299,7 +299,7 @@ def assert_specific_vm_powered_off :tools_status => nil, :boot_time => nil, :standby_action => nil, - :connection_state => nil, + :connection_state => "connected", :cpu_affinity => nil, :memory_reserve => nil, :memory_reserve_expand => nil,