Sha256: ba81f4a59efe0add5980039c4a53ab23247b4db2033b47078b2e0e97efb24dc7
Contents?: true
Size: 1.17 KB
Versions: 7
Compression:
Stored size: 1.17 KB
Contents
module Fog module OracleCloud class SOA class Real def delete_instance(service_name, dba_name, dba_password, options={}) body_data = { 'dbaName' => dba_name, 'dbaPassword' => dba_password, 'forceDelete' => options[:force_delete], 'skipBackupOnTerminate' => options[:skip_backup] } body_data = body_data.reject {|key, value| value.nil?} request( :method => 'PUT', :expects => 202, :path => "/paas/service/soa/api/v1.1/instances/#{@identity_domain}/#{service_name}", :body => Fog::JSON.encode(body_data) ) end end class Mock def delete_instance(service_name, dba_name, dba_password, options={}) response = Excon::Response.new # remove from memoreeeez. self.data[:instances].delete service_name response.body = { 'service_name' => service_name, 'status' => 'Terminating' } response.status = 202 response end end end end end
Version data entries
7 entries across 7 versions & 1 rubygems