Module Rudy::Metadata
In: lib/rudy/metadata.rb

Methods

==   build_criteria   connect   create_domain   descriptors   destroy   destroy   destroy_domain   domain   domain=   exists?   exists?   get   get_rclass   included   name   new   put   refresh!   save   select  

Included Modules

Rudy::Huxtable

Classes and Modules

Module Rudy::Metadata::ClassMethods
Module Rudy::Metadata::InstanceMethods
Class Rudy::Metadata::DuplicateRecord
Class Rudy::Metadata::UnknownObject
Class Rudy::Metadata::UnknownRecordType

Constants

COMMON_FIELDS = [:region, :zone, :environment, :role].freeze

Public Class methods

Generates a default criteria for all metadata based on region, zone, environment, and role. If a position has been specified in the globals it will also be included.

  • rtype is the record type. One of: m, disk, or back.
  • fields replaces and adds values to this criteria
  • less removes keys from the default criteria.

Returns a Hash.

Creates instances of the following and stores to class variables:

Creates a SimpleDB domain named n and updates +@@domain+ if successful

Destroys a SimpleDB domain named n and sets +@@domain+ to Rudy::DOMAIN

Get a record from SimpleDB with the key n

Generates and executes a SimpleDB select query based on the specified fields Hash. See self.build_criteria.

Returns a Hash. keys are SimpleDB object IDs and values are the object attributes.

Public Instance methods

Compares the names between two Rudy::Metadata objects.

Is there an object in SimpleDB where the key == self.name

Refresh the metadata object from SimpleDB. If the record doesn‘t exist it will raise an UnknownObject error

[Validate]