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=, attribute, aws_id_attribute, aws_id_prefix, #aws_object_id, aws_option_handlers, aws_sdk_class, aws_sdk_class_id, aws_sdk_option_name, aws_sdk_type, 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



34
35
36
37
38
39
40
# File 'lib/chef/resource/aws_rds_instance.rb', line 34

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



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

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

#rds_tagging_typeObject



48
49
50
# File 'lib/chef/resource/aws_rds_instance.rb', line 48

def rds_tagging_type
  "db"
end