Class: Chef::Resource::AwsRdsInstance

Constant Summary

Constants inherited from Provisioning::AWSDriver::AWSResource

Provisioning::AWSDriver::AWSResource::NOT_PASSED

Instance Method Summary collapse

Methods included from Provisioning::AWSDriver::AWSTaggable

included

Methods inherited from Provisioning::AWSDriver::AWSResource

#action, #action=, #aws_object_id, get_aws_object, get_aws_object_id, #initialize, lookup_options

Methods inherited from Provisioning::AWSDriver::SuperLWRP

#_pv_is, attribute, lazy

Constructor Details

This class inherits a constructor from Chef::Provisioning::AWSDriver::AWSResource

Instance Method Details

#aws_objectObject



30
31
32
33
34
35
36
# File 'lib/chef/resource/aws_rds_instance.rb', line 30

def aws_object
  result = self.driver.rds_resource.db_instance(name)
  return nil unless result && result.db_instance_status != 'deleting'
  result
rescue ::Aws::RDS::Errors::DBInstanceNotFound
  nil
end

#db_instance_statusObject



38
39
40
41
42
# File 'lib/chef/resource/aws_rds_instance.rb', line 38

def db_instance_status
  aws_object.db_instance_status if aws_object
rescue ::Aws::RDS::Errors::DBInstanceNotFound
  nil
end

#rds_tagging_typeObject



44
45
46
# File 'lib/chef/resource/aws_rds_instance.rb', line 44

def rds_tagging_type
  "db"
end