Sha256: d720be8ab08fe294473fabc8609e8f872d6c0a74dccaf24c8a9c47fa77ddca59

Contents?: true

Size: 1.64 KB

Versions: 97

Compression:

Stored size: 1.64 KB

Contents

module Fog
  module AWS
    class Redshift
      class Real
        require 'fog/aws/parsers/redshift/cluster_snapshot'

        # ==== Parameters
        #
        # @param [Hash] options
        # * :snapshot_identifier - required - (String)
        #    A unique identifier for the snapshot that you are requesting. This identifier
        #    must be unique for all snapshots within the AWS account. Constraints: Cannot be
        #    null, empty, or blank Must contain from 1 to 255 alphanumeric characters or
        #    hyphens First character must be a letter Cannot end with a hyphen or contain two
        #    consecutive hyphens Example: my-snapshot-id
        # * :cluster_identifier - required - (String)
        #    The cluster identifier for which you want a snapshot.
        #
        # ==== See Also
        # http://docs.aws.amazon.com/redshift/latest/APIReference/API_CreateClusterSnapshot.html
        def create_cluster_snapshot(options = {})
          snapshot_identifier  = options[:snapshot_identifier]
          cluster_identifier   = options[:cluster_identifier]

          path = "/"
          params = {
            :headers    => {},
            :path       => path,
            :method     => :put,
            :query      => {},
            :parser     => Fog::Parsers::Redshift::AWS::ClusterSnapshot.new
          }

          params[:query]['Action']             = 'CreateClusterSnapshot'
          params[:query]['SnapshotIdentifier'] = snapshot_identifier if snapshot_identifier
          params[:query]['ClusterIdentifier']  = cluster_identifier if cluster_identifier

          request(params)
        end
      end
    end
  end
end

Version data entries

97 entries across 95 versions & 6 rubygems

Version Path
fog-aws-3.29.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.28.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.27.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.26.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.25.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.24.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.23.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.22.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.21.1 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.21.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.20.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.19.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.18.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.17.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.16.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.15.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.14.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.13.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.12.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb
fog-aws-3.11.0 lib/fog/aws/requests/redshift/create_cluster_snapshot.rb