diff --git a/lib/fog/vcloud_director/requests/compute/post_configure_edge_gateway_services.rb b/lib/fog/vcloud_director/requests/compute/post_configure_edge_gateway_services.rb index 6e8c85324..2b09c020b 100644 --- a/lib/fog/vcloud_director/requests/compute/post_configure_edge_gateway_services.rb +++ b/lib/fog/vcloud_director/requests/compute/post_configure_edge_gateway_services.rb @@ -41,7 +41,10 @@ module Fog ) end - owner = {:href => '', :name => nil, :type => nil} #known-bug: admin-api does not return owner. + owner = { + :href => make_href("admin/edgeGateway/#{id}"), + :type => 'application/vnd.vmware.vcloud.gateway+xml' + } task_id = enqueue_task( "Configuring edgegateway(#{id})", 'networkConfigureEdgeGatewayServices', owner, :on_success => lambda do @@ -49,11 +52,14 @@ module Fog end ) + task = task_body(task_id) + task.delete(:Owner) # known bug - admin tasks do not return Owner + body = { :xmlns => xmlns, :xmlns_xsi => xmlns_xsi, :xsi_schemaLocation => xsi_schema_location, - }.merge(task_body(task_id)) + }.merge(task) Excon::Response.new( :status => 202, diff --git a/lib/fog/vcloud_director/requests/compute/put_network.rb b/lib/fog/vcloud_director/requests/compute/put_network.rb index bcff1b3a9..cb32c331b 100644 --- a/lib/fog/vcloud_director/requests/compute/put_network.rb +++ b/lib/fog/vcloud_director/requests/compute/put_network.rb @@ -131,19 +131,23 @@ module Fog network_body[:FenceMode] = configuration[:FenceMode] if ip_scope.key?(:FenceMode) end - owner = {:href => '', :name => nil, :type => nil} #known-bug: admin-api does not return owner. + owner = { + :href => make_href("#{type}/#{id}"), + :type => "application/vnd.vmware.vcloud.#{type}+xml" + } task_id = enqueue_task( "Updating #{type} #{name} (#{id})", 'networkUpdateNetwork', owner, :on_success => lambda do data[:networks][id] = network_body end ) - + task = task_body(task_id) + task.delete(:Owner) #known-bug: admin-api does not return owner. body = { :xmlns => xmlns, :xmlns_xsi => xmlns_xsi, :xsi_schemaLocation => xsi_schema_location, - }.merge(task_body(task_id)) + }.merge(task) Excon::Response.new( :status => 202,