Class: Fog::AWS::Redshift::Real
- Inherits:
-
Object
- Object
- Fog::AWS::Redshift::Real
- Includes:
- CredentialFetcher::ConnectionMethods
- Defined in:
- lib/fog/aws/redshift.rb,
lib/fog/aws/requests/redshift/create_cluster.rb,
lib/fog/aws/requests/redshift/delete_cluster.rb,
lib/fog/aws/requests/redshift/modify_cluster.rb,
lib/fog/aws/requests/redshift/reboot_cluster.rb,
lib/fog/aws/requests/redshift/describe_events.rb,
lib/fog/aws/requests/redshift/describe_resize.rb,
lib/fog/aws/requests/redshift/describe_clusters.rb,
lib/fog/aws/requests/redshift/copy_cluster_snapshot.rb,
lib/fog/aws/requests/redshift/revoke_snapshot_access.rb,
lib/fog/aws/requests/redshift/create_cluster_snapshot.rb,
lib/fog/aws/requests/redshift/delete_cluster_snapshot.rb,
lib/fog/aws/requests/redshift/describe_reserved_nodes.rb,
lib/fog/aws/requests/redshift/authorize_snapshot_access.rb,
lib/fog/aws/requests/redshift/describe_cluster_versions.rb,
lib/fog/aws/requests/redshift/describe_cluster_snapshots.rb,
lib/fog/aws/requests/redshift/create_cluster_subnet_group.rb,
lib/fog/aws/requests/redshift/delete_cluster_subnet_group.rb,
lib/fog/aws/requests/redshift/describe_cluster_parameters.rb,
lib/fog/aws/requests/redshift/modify_cluster_subnet_group.rb,
lib/fog/aws/requests/redshift/create_cluster_security_group.rb,
lib/fog/aws/requests/redshift/delete_cluster_security_group.rb,
lib/fog/aws/requests/redshift/reset_cluster_parameter_group.rb,
lib/fog/aws/requests/redshift/restore_from_cluster_snapshot.rb,
lib/fog/aws/requests/redshift/create_cluster_parameter_group.rb,
lib/fog/aws/requests/redshift/delete_cluster_parameter_group.rb,
lib/fog/aws/requests/redshift/describe_cluster_subnet_groups.rb,
lib/fog/aws/requests/redshift/modify_cluster_parameter_group.rb,
lib/fog/aws/requests/redshift/purchase_reserved_node_offering.rb,
lib/fog/aws/requests/redshift/describe_cluster_security_groups.rb,
lib/fog/aws/requests/redshift/describe_reserved_node_offerings.rb,
lib/fog/aws/requests/redshift/describe_cluster_parameter_groups.rb,
lib/fog/aws/requests/redshift/describe_orderable_cluster_options.rb,
lib/fog/aws/requests/redshift/describe_default_cluster_parameters.rb,
lib/fog/aws/requests/redshift/revoke_cluster_security_group_ingress.rb,
lib/fog/aws/requests/redshift/authorize_cluster_security_group_ingress.rb
Instance Method Summary collapse
- #authorize_cluster_security_group_ingress(options = {}) ⇒ Object
-
#authorize_snapshot_access(options = {}) ⇒ Object
Parameters.
-
#copy_cluster_snapshot(options = {}) ⇒ Object
Parameters.
- #create_cluster(options = {}) ⇒ Object
-
#create_cluster_parameter_group(options = {}) ⇒ Object
Parameters.
-
#create_cluster_security_group(options = {}) ⇒ Object
Parameters.
-
#create_cluster_snapshot(options = {}) ⇒ Object
Parameters.
-
#create_cluster_subnet_group(options = {}) ⇒ Object
Parameters.
-
#delete_cluster(options = {}) ⇒ Object
Parameters.
-
#delete_cluster_parameter_group(options = {}) ⇒ Object
Parameters.
-
#delete_cluster_security_group(options = {}) ⇒ Object
Parameters.
-
#delete_cluster_snapshot(options = {}) ⇒ Object
Parameters.
-
#delete_cluster_subnet_group(options = {}) ⇒ Object
Parameters.
-
#describe_cluster_parameter_groups(options = {}) ⇒ Object
Parameters.
-
#describe_cluster_parameters(options = {}) ⇒ Object
Parameters.
-
#describe_cluster_security_groups(options = {}) ⇒ Object
Parameters.
-
#describe_cluster_snapshots(options = {}) ⇒ Object
Parameters.
-
#describe_cluster_subnet_groups(cluster_subnet_group_name = nil, marker = nil, max_records = nil) ⇒ Object
Parameters.
-
#describe_cluster_versions(options = {}) ⇒ Object
Parameters.
-
#describe_clusters(options = {}) ⇒ Object
Parameters.
-
#describe_default_cluster_parameters(options = {}) ⇒ Object
Parameters.
-
#describe_events(options = {}) ⇒ Object
Parameters.
-
#describe_orderable_cluster_options(options = {}) ⇒ Object
Parameters.
-
#describe_reserved_node_offerings(options = {}) ⇒ Object
Parameters.
-
#describe_reserved_nodes(options = {}) ⇒ Object
Parameters.
-
#describe_resize(options = {}) ⇒ Object
Parameters.
-
#initialize(options = {}) ⇒ Real
constructor
Initialize connection to Redshift.
-
#modify_cluster(options = {}) ⇒ Object
Parameters.
-
#modify_cluster_parameter_group(options = {}) ⇒ Object
Parameters.
-
#modify_cluster_subnet_group(options = {}) ⇒ Object
Parameters.
-
#purchase_reserved_node_offering(options = {}) ⇒ Object
Parameters.
-
#reboot_cluster(options = {}) ⇒ Object
Parameters.
-
#reset_cluster_parameter_group(options = {}) ⇒ Object
Parameters.
-
#restore_from_cluster_snapshot(options = {}) ⇒ Object
Parameters.
- #revoke_cluster_security_group_ingress(options = {}) ⇒ Object
-
#revoke_snapshot_access(options = {}) ⇒ Object
Parameters.
Methods included from CredentialFetcher::ConnectionMethods
#refresh_credentials_if_expired
Constructor Details
#initialize(options = {}) ⇒ Real
Initialize connection to Redshift
Notes
options parameter must include values for :aws_access_key_id and :aws_secret_access_key in order to create a connection
Examples
ses = SES.new(
:aws_access_key_id => your_aws_access_key_id,
:aws_secret_access_key => your_aws_secret_access_key
)
Parameters
-
options<~Hash> - config arguments for connection. Defaults to {}.
-
region<~String> - optional region to use. For instance, ‘us-east-1’ and etc.
-
Returns
-
Redshift object with connection to AWS.
76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 |
# File 'lib/fog/aws/redshift.rb', line 76 def initialize(={}) @use_iam_profile = [:use_iam_profile] @region = [:region] || 'us-east-1' setup_credentials() @instrumentor = [:instrumentor] @instrumentor_name = [:instrumentor_name] || 'fog.aws.redshift' @connection_options = [:connection_options] || {} @host = [:host] || "redshift.#{@region}.amazonaws.com" @version = '2012-12-01' @path = [:path] || '/' @persistent = [:persistent] || false @port = [:port] || 443 @scheme = [:scheme] || 'https' @connection = Fog::XML::Connection.new("#{@scheme}://#{@host}:#{@port}#{@path}", @persistent, @connection_options) end |
Instance Method Details
#authorize_cluster_security_group_ingress(options = {}) ⇒ Object
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/fog/aws/requests/redshift/authorize_cluster_security_group_ingress.rb', line 28 def ( = {}) cluster_security_group_name = [:cluster_security_group_name] cidrip = [:cidrip] ec2_security_group_name = [:ec2_security_group_name] ec2_security_group_owner_id = [:ec2_security_group_owner_id] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::RevokeClusterSecurityGroupIngress.new } params[:query]['Action'] = 'AuthorizeClusterSecurityGroupIngress' params[:query]['ClusterSecurityGroupName'] = cluster_security_group_name if cluster_security_group_name params[:query]['CIDRIP'] = cidrip if cidrip params[:query]['EC2SecurityGroupName'] = ec2_security_group_name if ec2_security_group_name params[:query]['EC2SecurityGroupOwnerId'] = ec2_security_group_owner_id if ec2_security_group_owner_id request(params) end |
#authorize_snapshot_access(options = {}) ⇒ Object
Parameters
-
:snapshot_identifier - required - (String)
The identifier of the snapshot the account is authorized to restore.
-
:snapshot_cluster_identifier - (String)
-
:account_with_restore_access - required - (String)
The identifier of the AWS customer account authorized to restore the specified snapshot. #
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_CopyClusterSnapshot.html
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 |
# File 'lib/fog/aws/requests/redshift/authorize_snapshot_access.rb', line 18 def ( = {}) snapshot_identifier = [:snapshot_identifier] snapshot_cluster_identifier = [:snapshot_cluster_identifier] account_with_restore_access = [:account_with_restore_access] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::ClusterSnapshot.new } params[:query]['Action'] = 'AuthorizeSnapshotAccess' params[:query]['SnapshotIdentifier'] = snapshot_identifier if snapshot_identifier params[:query]['SnapshotClusterIdentifier'] = snapshot_cluster_identifier if snapshot_cluster_identifier params[:query]['AccountWithRestoreAccess'] = account_with_restore_access if account_with_restore_access request(params) end |
#copy_cluster_snapshot(options = {}) ⇒ Object
Parameters
-
:source_snapshot_identifier - required - (String)
The identifier for the source snapshot. Constraints: Must be the identifier for a valid automated snapshot whose state is "available".
-
:source_snapshot_cluster_identifier - (String)
-
:target_snapshot_identifier - required - (String)
The identifier given to the new manual snapshot. 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. Must be unique for the AWS account that is making the request.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_CopyClusterSnapshot.html
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
# File 'lib/fog/aws/requests/redshift/copy_cluster_snapshot.rb', line 22 def copy_cluster_snapshot( = {}) source_snapshot_identifier = [:source_snapshot_identifier] source_snapshot_cluster_identifier = [:source_snapshot_cluster_identifier] target_snapshot_identifier = [:target_snapshot_identifier] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::ClusterSnapshot.new } params[:query]['Action'] = 'CopyClusterSnapshot' params[:query]['SourceSnapshotIdentifier'] = source_snapshot_identifier if source_snapshot_identifier params[:query]['SourceSnapshotClusterIdentifier'] = source_snapshot_cluster_identifier if source_snapshot_cluster_identifier params[:query]['TargetSnapshotIdentifier'] = target_snapshot_identifier if target_snapshot_identifier request(params) end |
#create_cluster(options = {}) ⇒ Object
85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 |
# File 'lib/fog/aws/requests/redshift/create_cluster.rb', line 85 def create_cluster( = {}) db_name = [:db_name] cluster_identifier = [:cluster_identifier] cluster_type = [:cluster_type] node_type = [:node_type] master_username = [:master_username] master_user_password = [:master_user_password] cluster_subnet_group_name = [:cluster_subnet_group_name] availability_zone = [:availability_zone] preferred_maintenance_window = [:preferred_maintenance_window] cluster_parameter_group_name = [:cluster_parameter_group_name] automated_snapshot_retention_period = [:automated_snapshot_retention_period] port = [:port] cluster_version = [:cluster_version] allow_version_upgrade = [:allow_version_upgrade] number_of_nodes = [:number_of_nodes] publicly_accessible = [:publicly_accessible] encrypted = [:encrypted] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::Cluster.new } if cluster_security_groups = .delete(:ClusterSecurityGroups) params[:query].merge!(Fog::AWS.indexed_param('ClusterSecurityGroups.member.%d', [*cluster_security_groups])) end if vpc_security_group_ids = .delete(:VpcSecurityGroupIds) params[:query].merge!(Fog::AWS.indexed_param('VpcSecurityGroupIds.member.%d', [*vpc_security_group_ids])) end params[:query]['Action'] = 'CreateCluster' params[:query]['DBName'] = db_name if db_name params[:query]['ClusterIdentifier'] = cluster_identifier if cluster_identifier params[:query]['ClusterType'] = cluster_type if cluster_type params[:query]['NodeType'] = node_type if node_type params[:query]['MasterUsername'] = master_username if master_username params[:query]['MasterUserPassword'] = master_user_password if master_user_password params[:query]['ClusterSecurityGroups'] = cluster_security_groups if cluster_security_groups params[:query]['VpcSecurityGroupIds'] = vpc_security_group_ids if vpc_security_group_ids params[:query]['ClusterSubnetGroupName'] = cluster_subnet_group_name if cluster_subnet_group_name params[:query]['AvailabilityZone'] = availability_zone if availability_zone params[:query]['PreferredMaintenanceWindow'] = preferred_maintenance_window if preferred_maintenance_window params[:query]['ClusterParameterGroupName'] = cluster_parameter_group_name if cluster_parameter_group_name params[:query]['AutomatedSnapshotRetentionPeriod'] = automated_snapshot_retention_period if automated_snapshot_retention_period params[:query]['Port'] = port if port params[:query]['ClusterVersion'] = cluster_version if cluster_version params[:query]['AllowVersionUpgrade'] = allow_version_upgrade if allow_version_upgrade params[:query]['NumberOfNodes'] = number_of_nodes if number_of_nodes params[:query]['PubliclyAccessible'] = publicly_accessible if publicly_accessible params[:query]['Encrypted'] = encrypted if encrypted request(params) end |
#create_cluster_parameter_group(options = {}) ⇒ Object
Parameters
-
:parameter_group_name - required - (String)
The name of the cluster parameter group. Constraints: Must be 1 to 255 alphanumeric characters or hyphens First character must be a letter. Cannot end with a hyphen or contain two consecutive hyphens. Must be unique within your AWS account. This value is stored as a lower-case string.
-
:parameter_group_family - required - (String)
The Amazon Redshift engine version to which the cluster parameter group applies. The cluster engine version determines the set of parameters. To get a list of valid parameter group family names, you can call DescribeClusterParameterGroups. By default, Amazon Redshift returns a list of all the parameter groups that are owned by your AWS account, including the default parameter groups for each Amazon Redshift engine version. The parameter group family names associated with the default parameter groups provide you the valid values. For example, a valid family name is "redshift-1.0".
-
:description - required - (String)
A description of the parameter group.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_CreateClusterParameterGroup.html
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 |
# File 'lib/fog/aws/requests/redshift/create_cluster_parameter_group.rb', line 28 def create_cluster_parameter_group( = {}) parameter_group_name = [:parameter_group_name] parameter_group_family = [:parameter_group_family] description = [:description] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::CreateClusterParameterGroup.new } params[:query]['Action'] = 'CreateClusterParameterGroup' params[:query]['ParameterGroupName'] = parameter_group_name if parameter_group_name params[:query]['ParameterGroupFamily'] = parameter_group_family if parameter_group_family params[:query]['Description'] = description if description request(params) end |
#create_cluster_security_group(options = {}) ⇒ Object
Parameters
-
:cluster_security_group_name - (String)
The name of a cluster security group for which you are requesting details. You can specify either the Marker parameter or a ClusterSecurityGroupName parameter, but not both. Example: securitygroup1
-
:description - required - (String)
A description for the security group.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_CreateClusterSecurityGroup.html
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 |
# File 'lib/fog/aws/requests/redshift/create_cluster_security_group.rb', line 19 def create_cluster_security_group( = {}) cluster_security_group_name = [:cluster_security_group_name] description = [:description] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::CreateClusterSecurityGroup.new } params[:query]['Action'] = 'CreateClusterSecurityGroup' params[:query]['ClusterSecurityGroupName'] = cluster_security_group_name if cluster_security_group_name params[:query]['Description'] = description if description request(params) end |
#create_cluster_snapshot(options = {}) ⇒ Object
Parameters
-
: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
docs.aws.amazon.com/redshift/latest/APIReference/API_CreateClusterSnapshot.html
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/fog/aws/requests/redshift/create_cluster_snapshot.rb', line 21 def create_cluster_snapshot( = {}) snapshot_identifier = [:snapshot_identifier] cluster_identifier = [: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 |
#create_cluster_subnet_group(options = {}) ⇒ Object
Parameters
-
:cluster_subnet_group_name - required - (String)
The name for the subnet group. Amazon Redshift stores the value as a lowercase string. Constraints: Must contain no more than 255 alphanumeric characters or hyphens. Must not be "Default". Must be unique for all subnet groups that are created by your AWS account. Example: examplesubnetgroup
-
:description - required - (String)
A description of the parameter group.
-
:subnet_ids - required - (Array<)
An array of VPC subnet IDs. A maximum of 20 subnets can be modified in a single request.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_CreateClusterSubnetGroup.html
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/fog/aws/requests/redshift/create_cluster_subnet_group.rb', line 22 def create_cluster_subnet_group( = {}) cluster_subnet_group_name = [:cluster_subnet_group_name] description = [:description] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::ClusterSubnetGroupParser.new } if subnet_ids = .delete(:subnet_ids) params[:query].merge!(Fog::AWS.indexed_param('SubnetIds.member.%d', [*subnet_ids])) end params[:query]['Action'] = 'CreateClusterSubnetGroup' params[:query]['ClusterSubnetGroupName'] = cluster_subnet_group_name if cluster_subnet_group_name params[:query]['Description'] = description if description request(params) end |
#delete_cluster(options = {}) ⇒ Object
Parameters
-
:cluster_identifier - required - (String)
A unique identifier for the cluster. You use this identifier to refer to the cluster for any subsequent cluster operations such as deleting or modifying. Must be unique for all clusters within an AWS account. Example: myexamplecluster
-
:skip_final_cluster_snapshot - (Boolean)
Determines whether a final snapshot of the cluster is created before Amazon Redshift deletes the cluster. If `true` , a final cluster snapshot is not created. If `false`, a final cluster snapshot is created before the cluster is deleted. The FinalClusterSnapshotIdentifier parameter must be specified if SkipFinalClusterSnapshot is `false` . Default: `false`
-
:final_cluster_snapshot_identifier - (String)
The identifier of the final snapshot that is to be created immediately before deleting the cluster. If this parameter is provided, SkipFinalClusterSnapshot must be `false`. Constraints: Must be 1 to 255 alphanumeric characters. First character must be a letter Cannot end with a hyphen or contain two consecutive hyphens.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DeleteCluster.html
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 |
# File 'lib/fog/aws/requests/redshift/delete_cluster.rb', line 27 def delete_cluster( = {}) cluster_identifier = [:cluster_identifier] final_cluster_snapshot_identifier = [:final_cluster_snapshot_identifier] skip_final_cluster_snapshot = [:skip_final_cluster_snapshot] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::Cluster.new } params[:query]['Action'] = 'DeleteCluster' params[:query]['ClusterIdentifier'] = cluster_identifier if cluster_identifier params[:query]['FinalClusterSnapshotIdentifier'] = final_cluster_snapshot_identifier if final_cluster_snapshot_identifier params[:query]['SkipFinalClusterSnapshot'] = skip_final_cluster_snapshot if skip_final_cluster_snapshot request(params) end |
#delete_cluster_parameter_group(options = {}) ⇒ Object
Parameters
-
:parameter_group_name - required - (String)
The name of the parameter group to be deleted. Constraints: Must be the name of an existing cluster parameter group. Cannot delete a default cluster parameter group.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DeleteClusterParameterGroup.html
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 |
# File 'lib/fog/aws/requests/redshift/delete_cluster_parameter_group.rb', line 14 def delete_cluster_parameter_group( = {}) parameter_group_name = [:parameter_group_name] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {} } params[:query]['Action'] = 'DeleteClusterParameterGroup' params[:query]['ParameterGroupName'] = parameter_group_name if parameter_group_name request(params) end |
#delete_cluster_security_group(options = {}) ⇒ Object
Parameters
-
:cluster_security_group_name - required - (String)
The name of the cluster security group to be deleted.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DeleteClusterSecurityGroup.html
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'lib/fog/aws/requests/redshift/delete_cluster_security_group.rb', line 13 def delete_cluster_security_group( = {}) cluster_security_group_name = [:cluster_security_group_name] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {} } params[:query]['Action'] = 'DeleteClusterSecurityGroup' params[:query]['ClusterSecurityGroupName'] = cluster_security_group_name if cluster_security_group_name request(params) end |
#delete_cluster_snapshot(options = {}) ⇒ Object
Parameters
-
: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
-
:snapshot_cluster_identifier - required - (String)
The cluster identifier for which you want a snapshot.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_CreateClusterSnapshot.html
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/fog/aws/requests/redshift/delete_cluster_snapshot.rb', line 21 def delete_cluster_snapshot( = {}) snapshot_identifier = [:snapshot_identifier] snapshot_cluster_identifier = [:snapshot_cluster_identifier] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::ClusterSnapshot.new } params[:query]['Action'] = 'DeleteClusterSnapshot' params[:query]['SnapshotIdentifier'] = snapshot_identifier if snapshot_identifier params[:query]['SnapshotClusterIdentifier'] = snapshot_cluster_identifier if snapshot_cluster_identifier request(params) end |
#delete_cluster_subnet_group(options = {}) ⇒ Object
Parameters
-
:cluster_subnet_group_name - required - (String)
The name for the subnet group. Amazon Redshift stores the value as a lowercase string. Constraints: Must contain no more than 255 alphanumeric characters or hyphens. Must not be "Default". Must be unique for all subnet groups that are created by your AWS account. Example: examplesubnetgroup
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DeleteClusterSubnetGroup.html
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
# File 'lib/fog/aws/requests/redshift/delete_cluster_subnet_group.rb', line 16 def delete_cluster_subnet_group( = {}) cluster_subnet_group_name = [:cluster_subnet_group_name] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :delete, :query => {} } params[:query]['Action'] = 'DeleteClusterSubnetGroup' params[:query]['ClusterSubnetGroupName'] = cluster_subnet_group_name if cluster_subnet_group_name request(params) end |
#describe_cluster_parameter_groups(options = {}) ⇒ Object
Parameters
-
:parameter_group_name (String)
The name of a cluster parameter group for which to return details.
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeClusterParameterGroups.html
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/fog/aws/requests/redshift/describe_cluster_parameter_groups.rb', line 22 def describe_cluster_parameter_groups( = {}) parameter_group_name = [:parameter_group_name] marker = [:marker] max_records = [:max_records] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeClusterParameterGroups.new } params[:query]['Action'] = 'DescribeClusterParameterGroups' params[:query]['ParameterGroupName'] = parameter_group_name if parameter_group_name params[:query]['Marker'] = marker if marker params[:query]['MaxRecords'] = max_records if max_records request(params) end |
#describe_cluster_parameters(options = {}) ⇒ Object
Parameters
-
:parameter_group_name - required - (String)
The name of a cluster parameter group for which to return details.
-
:source - (String)
The parameter types to return. Specify user to show parameters that are different form the default. Similarly, specify engine-default to show parameters that are the same as the default parameter group. Default: All parameter types returned. Valid Values: user | engine-default
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeClusterParameters.html
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/fog/aws/requests/redshift/describe_cluster_parameters.rb', line 27 def describe_cluster_parameters( = {}) parameter_group_name = [:parameter_group_name] source = [:source] marker = [:marker] max_records = [:max_records] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeClusterParameters.new } params[:query]['Action'] = 'DescribeClusterParameters' params[:query]['ParameterGroupName'] = parameter_group_name if parameter_group_name params[:query]['Source'] = source if source params[:query]['Marker'] = marker if marker params[:query]['MaxRecords'] = max_records if max_records request(params) end |
#describe_cluster_security_groups(options = {}) ⇒ Object
Parameters
-
:cluster_security_group_name - (String)
The name of a cluster security group for which you are requesting details. You can specify either the Marker parameter or a ClusterSecurityGroupName parameter, but not both. Example: securitygroup1
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeClusterSecurityGroups.html
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/fog/aws/requests/redshift/describe_cluster_security_groups.rb', line 24 def describe_cluster_security_groups( = {}) cluster_security_group_name = [:cluster_security_group_name] marker = [:marker] max_records = [:max_records] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeClusterSecurityGroups.new } params[:query]['Action'] = 'DescribeClusterSecurityGroups' params[:query]['ClusterSecurityGroupName'] = cluster_security_group_name if cluster_security_group_name params[:query]['Marker'] = marker if marker params[:query]['MaxRecords'] = max_records if max_records request(params) end |
#describe_cluster_snapshots(options = {}) ⇒ Object
Parameters
-
:cluster_identifier - (String)
The identifier of the cluster for which information about snapshots is requested.
-
:snapshot_identifier - (String)
The snapshot identifier of the snapshot about which to return information.
-
:snapshot_type - (String)
The type of snapshots for which you are requesting information. By default, snapshots of all types are returned. Valid Values: automated | manual
-
:start_time - (String)
A value that requests only snapshots created at or after the specified time. The time value is specified in ISO 8601 format. For more information about ISO 8601, go to the ISO8601 Wikipedia page. Example: 2012-07-16T18:00:00Z
-
:end_time - (String)
A time value that requests only snapshots created at or before the specified time. The time value is specified in ISO 8601 format. For more information about ISO 8601, go to the ISO8601 Wikipedia page. Example: 2012-07-16T18:00:00Z
-
:owner_account - (String)
The AWS customer account used to create or copy the snapshot. Use this field to filter the results to snapshots owned by a particular account. To describe snapshots you own, either specify your AWS customer account, or do not specify the parameter.
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeClusterSnapshots.html
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 |
# File 'lib/fog/aws/requests/redshift/describe_cluster_snapshots.rb', line 39 def describe_cluster_snapshots( = {}) cluster_identifier = [:cluster_identifier] snapshot_identifier = [:snapshot_identifier] start_time = [:start_time] end_time = [:end_time] owner_account = [:owner_account] marker = [:marker] max_records = [:max_records] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeClusterSnapshots.new } params[:query]['Action'] = 'DescribeClusterSnapshots' params[:query]['ClusterIdentifier'] = cluster_identifier if cluster_identifier params[:query]['SnapshotIdentifier'] = snapshot_identifier if snapshot_identifier params[:query]['start_time'] = start_time if start_time params[:query]['end_time'] = end_time if end_time params[:query]['OwnerAccount'] = owner_account if owner_account params[:query]['Marker'] = marker if marker params[:query]['MaxRecords'] = max_records if max_records request(params) end |
#describe_cluster_subnet_groups(cluster_subnet_group_name = nil, marker = nil, max_records = nil) ⇒ Object
Parameters
-
:cluster_subnet_group_name - (String)
The name of the cluster subnet group for which information is requested.
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
Returns
-
response<~Excon::Response>:
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeClusterSubnetGroups.html
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
# File 'lib/fog/aws/requests/redshift/describe_cluster_subnet_groups.rb', line 25 def describe_cluster_subnet_groups(cluster_subnet_group_name=nil, marker=nil,max_records=nil) path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeClusterSubnetGroups.new } params[:query]['Action'] = 'DescribeClusterSubnetGroups' params[:query]['ClusterSubnetGroupName'] = cluster_subnet_group_name if cluster_subnet_group_name params[:query]['Marker'] = marker if marker params[:query]['MaxRecords'] = max_records if max_records request(params) end |
#describe_cluster_versions(options = {}) ⇒ Object
Parameters
-
:cluster_parameter_group_family - (String)
The name of a specific cluster parameter group family to return details for. Constraints: Must be 1 to 255 alphanumeric characters. First character must be a letter, and cannot end with a hyphen or contain two consecutive hyphens.
-
:cluster_version - (String)
The specific cluster version to return. Example: 1.0
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeClusterVersions.html
26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 |
# File 'lib/fog/aws/requests/redshift/describe_cluster_versions.rb', line 26 def describe_cluster_versions( = {}) cluster_version = [:cluster_version] cluster_parameter_group_family = [:cluster_parameter_group_family] marker = [:marker] max_records = [:max_records] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeClusterVersions.new } params[:query]['Action'] = 'DescribeClusterVersions' params[:query]['ClusterVersion'] = cluster_version if cluster_version params[:query]['ClusterParameterGroupFamily'] = cluster_parameter_group_family if cluster_parameter_group_family params[:query]['Marker'] = marker if marker params[:query]['MaxRecords'] = max_records if max_records request(params) end |
#describe_clusters(options = {}) ⇒ Object
Parameters
-
:cluster_identifier - (String)
The unique identifier of a cluster whose properties you are requesting. This parameter isn't case sensitive. The default is that all clusters defined for an account are returned.
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeClusters.html
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/fog/aws/requests/redshift/describe_clusters.rb', line 24 def describe_clusters( = {}) cluster_identifier = [:cluster_identifier] marker = [:marker] max_records = [:max_records] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeClusters.new } params[:query]['Action'] = 'DescribeClusters' params[:query]['ClusterIdentifier'] = cluster_identifier if cluster_identifier params[:query]['MaxRecords'] = max_records if max_records params[:query]['Marker'] = marker if marker request(params) end |
#describe_default_cluster_parameters(options = {}) ⇒ Object
Parameters
-
:parameter_group_family - required - (String)
The name of a cluster parameter group family for which to return details.
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeDefaultClusterParameters.html
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 |
# File 'lib/fog/aws/requests/redshift/describe_default_cluster_parameters.rb', line 22 def describe_default_cluster_parameters( = {}) parameter_group_family = [:parameter_group_family] source = [:source] marker = [:marker] max_records = [:max_records] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeDefaultClusterParameters.new } params[:query]['Action'] = 'DescribeDefaultClusterParameters' params[:query]['ParameterGroupFamily'] = parameter_group_family if parameter_group_family params[:query]['Marker'] = marker if marker params[:query]['MaxRecords'] = max_records if max_records request(params) end |
#describe_events(options = {}) ⇒ Object
Parameters
-
:source_identifier - (String)
The identifier of the event source for which events will be returned. If this parameter is not specified, then all sources are included in the response. Constraints: If SourceIdentifier is supplied, SourceType must also be provided. Specify a cluster identifier when SourceType is cluster. Specify a cluster security group name when SourceType is cluster-security-group. Specify a cluster parameter group name when SourceType is cluster-parameter-group. Specify a cluster snapshot identifier when SourceType is cluster-snapshot.
-
:source_type - (String)
The event source to retrieve events for. If no value is specified, all events are returned. Constraints: If SourceType is supplied, SourceIdentifier must also be provided. Specify cluster when SourceIdentifier is a cluster identifier. Specify cluster-security-group when SourceIdentifier is a cluster security group name. Specify cluster-parameter-group when SourceIdentifier is a cluster parameter group name. Specify cluster-snapshot when SourceIdentifier is a cluster snapshot identifier. Valid values include: cluster, cluster-parameter-group, cluster-security-group, cluster-snapshot
-
:start_time - (String<)
The beginning of the time interval to retrieve events for, specified in ISO 8601 format. Example: 2009-07-08T18:00Z
-
:end_time - (String<)
The end of the time interval for which to retrieve events, specified in ISO 8601 format. Example: 2009-07-08T18:00Z
-
:duration - (Integer)
The number of minutes prior to the time of the request for which to retrieve events. For example, if the request is sent at 18:00 and you specify a duration of 60, then only events which have occurred after 17:00 will be returned. Default: 60
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeEvents.html
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 |
# File 'lib/fog/aws/requests/redshift/describe_events.rb', line 46 def describe_events( = {}) source_identifier = [:source_identifier] source_type = [:source_type] start_time = [:start_time] end_time = [:end_time] duration = [:duration] marker = [:marker] max_records = [:max_records] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeEvents.new } params[:query]['Action'] = 'DescribeEvents' params[:query]['SourceIdentifier'] = source_identifier if source_identifier params[:query]['SourceType'] = source_type if source_type params[:query]['StartTime'] = start_time if start_time params[:query]['EndTime'] = end_time if end_time params[:query]['Duration'] = duration if duration params[:query]['Marker'] = marker if marker params[:query]['MaxRecords'] = max_records if max_records request(params) end |
#describe_orderable_cluster_options(options = {}) ⇒ Object
Parameters
-
:cluster_version - (String)
The version filter value. Specify this parameter to show only the available offerings matching the specified version. Default: All versions. Constraints: Must be one of the version returned from DescribeClusterVersions.
-
:node_type - (String)
The node type filter value. Specify this parameter to show only the available offerings matching the specified node type.
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeOrderableClusterOptions.html
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/fog/aws/requests/redshift/describe_orderable_cluster_options.rb', line 27 def ( = {}) cluster_version = [:cluster_version] node_type = [:node_type] marker = [:marker] max_records = [:max_records] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeOrderableClusterOptions.new } params[:query]['Action'] = 'DescribeOrderableClusterOptions' params[:query]['ClusterVersion'] = cluster_version if cluster_version params[:query]['NodeType'] = node_type if node_type params[:query]['Marker'] = marker if marker params[:query]['MaxRecords'] = max_records if max_records request(params) end |
#describe_reserved_node_offerings(options = {}) ⇒ Object
Parameters
-
:reserved_node_offering_id - (String)
The unique identifier for the offering.
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeReservedNodeOfferings.html
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/fog/aws/requests/redshift/describe_reserved_node_offerings.rb', line 22 def describe_reserved_node_offerings( = {}) reserved_node_offering_id = [:reserved_node_offering_id] marker = [:marker] max_records = [:max_records] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeReservedNodeOfferings.new } params[:query]['Action'] = 'DescribeReservedNodeOfferings' params[:query]['ReservedNodeOfferingId'] = reserved_node_offering_id if reserved_node_offering_id params[:query]['Marker'] = marker if marker params[:query]['MaxRecords'] = max_records if max_records request(params) end |
#describe_reserved_nodes(options = {}) ⇒ Object
Parameters
-
:reserved_node_id - (String)
The unique identifier for the node reservation.
-
:max_records - (Integer)
The maximum number of records to include in the response. If more than the MaxRecords value is available, a marker is included in the response so that the following results can be retrieved. Constrained between [20,100]. Default is 100.
-
:marker - (String)
The marker returned from a previous request. If this parameter is specified, the response includes records beyond the marker only, up to MaxRecords.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeReservedNodes.html
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/fog/aws/requests/redshift/describe_reserved_nodes.rb', line 22 def describe_reserved_nodes( = {}) reserved_node_id = [:reserved_node_id] marker = [:marker] max_records = [:max_records] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeReservedNodes.new } params[:query]['Action'] = 'DescribeReservedNodes' params[:query]['ReservedNodeId'] = reserved_node_id if reserved_node_id params[:query]['Marker'] = marker if marker params[:query]['MaxRecords'] = max_records if max_records request(params) end |
#describe_resize(options = {}) ⇒ Object
Parameters
-
:cluster_identifier - required - (String)
The unique identifier of a cluster whose resize progress you are requesting. This parameter isn't case-sensitive. By default, resize operations for all clusters defined for an AWS account are returned.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DescribeResize.html
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 |
# File 'lib/fog/aws/requests/redshift/describe_resize.rb', line 17 def describe_resize( = {}) cluster_identifier = [:cluster_identifier] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :get, :query => {}, :parser => Fog::Parsers::Redshift::AWS::DescribeResize.new } params[:query]['Action'] = 'DescribeResize' params[:query]['ClusterIdentifier'] = cluster_identifier if cluster_identifier request(params) end |
#modify_cluster(options = {}) ⇒ Object
Parameters
-
:cluster_identifier - required - (String)
A unique identifier for the cluster. You use this identifier to refer to the cluster for any subsequent cluster operations such as deleting or modifying. Must be unique for all clusters within an AWS account. Example: myexamplecluster
-
:allow_version_upgrade - (Boolean)
If `true` , upgrades can be applied during the maintenance window to the Amazon Redshift engine that is running on the cluster. Default: `true`
-
:automated_snapshot_retention_period - (Integer)
Number of days that automated snapshots are retained. If the value is 0, automated snapshots are disabled. Default: 1 Constraints: Must be a value from 0 to 35.
-
:cluster_parameter_group_name - (String)
The name of the parameter group to be associated with this cluster. Default: The default Amazon Redshift cluster parameter group. Constraints: Must be 1 to 255 alphanumeric characters or hyphens. First character must be a letter. Cannot end with a hyphen or contain two consecutive hyphens.
-
:cluster_security_groups - (Array<String>)
A list of security groups to be associated with this cluster. Default: The default cluster security group for Amazon Redshift.
-
:cluster_type - (String)
Type of the cluster. When cluster type is specified as single-node, the NumberOfNodes parameter is not required. multi-node, the NumberOfNodes parameter is required. Valid Values: multi-node | single-node Default: multi-node
-
:cluster_version - (String)
The version of the Amazon Redshift engine software that you want to deploy on the cluster. The version selected runs on all the nodes in the cluster. Constraints: Only version 1.0 is currently available. Example: 1.0
-
:master_user_password - required - (String)
The password associated with the master user account for the cluster that is being created. Constraints: Must be between 8 and 64 characters in length. Must contain at least one uppercase letter. Must contain at least one lowercase letter. Must contain one number.
-
:node_type - required - (String)
The node type to be provisioned. Valid Values: dw.hs1.xlarge | dw.hs1.8xlarge.
-
:number_of_nodes - (Integer)
The number of compute nodes in the cluster. This parameter is required when the ClusterType parameter is specified as multi-node. If you don't specify this parameter, you get a single-node cluster. When requesting a multi-node cluster, you must specify the number of nodes that you want in the cluster. Default: 1 Constraints: Value must be at least 1 and no more than 100.
-
:preferred_maintenance_window - (String)
The weekly time range (in UTC) during which automated cluster maintenance can occur. Format: ddd:hh24:mi-ddd:hh24:mi Default: A 30-minute window selected at random from an 8-hour block of time per region, occurring on a random day of the week. Constraints: Minimum 30-minute window.
-
:vpc_security_group_ids - (Array<String>)
A list of Virtual Private Cloud (VPC) security groups to be associated with the cluster. Default: The default VPC security group is associated with the cluster.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_CreateCluster.html
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 |
# File 'lib/fog/aws/requests/redshift/modify_cluster.rb', line 60 def modify_cluster( = {}) cluster_identifier = [:cluster_identifier] cluster_type = [:cluster_type] node_type = [:node_type] master_user_password = [:master_user_password] preferred_maintenance_window = [:preferred_maintenance_window] cluster_parameter_group_name = [:cluster_parameter_group_name] automated_snapshot_retention_period = [:automated_snapshot_retention_period] cluster_version = [:cluster_version] allow_version_upgrade = [:allow_version_upgrade] number_of_nodes = [:number_of_nodes] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::Cluster.new } if cluster_security_groups = .delete(:ClusterSecurityGroups) params[:query].merge!(Fog::AWS.indexed_param('ClusterSecurityGroups.member.%d', [*cluster_security_groups])) end if vpc_security_group_ids = .delete(:VpcSecurityGroupIds) params[:query].merge!(Fog::AWS.indexed_param('VpcSecurityGroupIds.member.%d', [*vpc_security_group_ids])) end params[:query]['Action'] = 'ModifyCluster' params[:query]['ClusterIdentifier'] = cluster_identifier if cluster_identifier params[:query]['ClusterParameterGroupName'] = cluster_parameter_group_name if cluster_parameter_group_name params[:query]['ClusterType'] = cluster_type if cluster_type params[:query]['NodeType'] = node_type if node_type params[:query]['MasterUserPassword'] = master_user_password if master_user_password params[:query]['PreferredMaintenanceWindow'] = preferred_maintenance_window if preferred_maintenance_window params[:query]['AutomatedSnapshotRetentionPeriod'] = automated_snapshot_retention_period if automated_snapshot_retention_period params[:query]['ClusterVersion'] = cluster_version if cluster_version params[:query]['AllowVersionUpgrade'] = allow_version_upgrade if allow_version_upgrade params[:query]['NumberOfNodes'] = number_of_nodes if number_of_nodes params[:query]['ClusterSecurityGroups'] = cluster_security_groups if cluster_security_groups params[:query]['VpcSecurityGroupIds'] = vpc_security_group_ids if vpc_security_group_ids request(params) end |
#modify_cluster_parameter_group(options = {}) ⇒ Object
Parameters
-
:parameter_group_name - required - (String)
The name of the parameter group to be deleted. Constraints: Must be the name of an existing cluster parameter group. Cannot delete a default cluster parameter group.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_ModifyClusterParameterGroup.html
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'lib/fog/aws/requests/redshift/modify_cluster_parameter_group.rb', line 16 def modify_cluster_parameter_group( = {}) parameter_group_name = [:parameter_group_name] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::UpdateClusterParameterGroupParser.new } params[:query]['Action'] = 'ModifyClusterParameterGroup' params[:query]['ParameterGroupName'] = parameter_group_name if parameter_group_name if ['Parameters'] ['Parameters'].keys.each_with_index do |name, index| params[:query].merge!({ "Parameters.member.#{index+1}.#{name}" => ['Parameters'][name] }) end end request(params) end |
#modify_cluster_subnet_group(options = {}) ⇒ Object
Parameters
-
:cluster_subnet_group_name - required - (String)
The name for the subnet group. Amazon Redshift stores the value as a lowercase string. Constraints: Must contain no more than 255 alphanumeric characters or hyphens. Must not be "Default". Must be unique for all subnet groups that are created by your AWS account. Example: examplesubnetgroup
-
:description - required - (String)
A description of the parameter group.
-
:subnet_ids - required - (Array<)
An array of VPC subnet IDs. A maximum of 20 subnets can be modified in a single request.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_ModifyClusterSubnetGroup.html
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/fog/aws/requests/redshift/modify_cluster_subnet_group.rb', line 22 def modify_cluster_subnet_group( = {}) cluster_subnet_group_name = [:cluster_subnet_group_name] description = [:description] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::ClusterSubnetGroupParser.new } if subnet_ids = .delete(:subnet_ids) params[:query].merge!(Fog::AWS.indexed_param('SubnetIds.member.%d', [*subnet_ids])) end params[:query]['Action'] = 'ModifyClusterSubnetGroup' params[:query]['ClusterSubnetGroupName'] = cluster_subnet_group_name if cluster_subnet_group_name params[:query]['Description'] = description if description request(params) end |
#purchase_reserved_node_offering(options = {}) ⇒ Object
Parameters
-
:reserved_node_offering_id - required - (String)
The unique identifier of the reserved node offering you want to purchase.
-
:node_count - (Integer)
The number of reserved nodes you want to purchase. Default: 1
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_PurchaseReservedNodeOffering.html
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 |
# File 'lib/fog/aws/requests/redshift/purchase_reserved_node_offering.rb', line 17 def purchase_reserved_node_offering( = {}) reserved_node_offering_id = [:reserved_node_offering_id] node_count = [:node_count] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::PurchaseReservedNodeOffering.new } params[:query]['Action'] = 'PurchaseReservedNodeOffering' params[:query]['ReservedNodeOfferingId'] = reserved_node_offering_id if reserved_node_offering_id params[:query]['NodeCount'] = node_count if node_count request(params) end |
#reboot_cluster(options = {}) ⇒ Object
Parameters
-
:cluster_identifier - required - (String)
A unique identifier for the cluster. You use this identifier to refer to the cluster for any subsequent cluster operations such as deleting or modifying. Must be unique for all clusters within an AWS account. Example: myexamplecluster
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_DeleteCluster.html
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
# File 'lib/fog/aws/requests/redshift/reboot_cluster.rb', line 17 def reboot_cluster( = {}) cluster_identifier = [:cluster_identifier] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::Cluster.new } params[:query]['Action'] = 'RebootCluster' params[:query]['ClusterIdentifier'] = cluster_identifier if cluster_identifier request(params) end |
#reset_cluster_parameter_group(options = {}) ⇒ Object
Parameters
-
:parameter_group_name - required - (String) The name of the cluster parameter group to be reset.
-
:reset_all_parameters - (Boolean) If true , all parameters in the specified parameter group will be reset to their default values. Default: true
-
:parameters - (Array<) An array of names of parameters to be reset. If ResetAllParameters option is not used, then at least one parameter name must be supplied. Constraints: A maximum of 20 parameters can be reset in a single request.
-
:parameter_name - (String) The name of the parameter.
-
:parameter_value - (String) The value of the parameter.
-
:description - (String) A description of the parameter.
-
:source - (String) The source of the parameter value, such as “engine-default” or “user”.
-
:data_type - (String) The data type of the parameter.
-
:allowed_values - (String) The valid range of values for the parameter.
-
:is_modifiable - (Boolean) If true , the parameter can be modified. Some parameters have security or operational implications that prevent them from being changed.
-
:minimum_engine_version - (String) The earliest engine version to which the parameter can apply.
-
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_ResetClusterParameterGroup.html
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/fog/aws/requests/redshift/reset_cluster_parameter_group.rb', line 24 def reset_cluster_parameter_group( = {}) parameter_group_name = [:parameter_group_name] reset_all_parameters = [:reset_all_parameters] path = "/" params = { :idempotent => true, :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::UpdateClusterParameterGroupParser.new } if ['Parameters'] ['Parameters'].keys.each_with_index do |name, index| params[:query].merge!({ "Parameters.member.#{index+1}.#{name}" => ['Parameters'][name] }) end end params[:query]['Action'] = 'ResetClusterSubnetGroup' params[:query]['ParameterGroupName'] = parameter_group_name if parameter_group_name params[:query]['ResetAllParameters'] = reset_all_parameters if reset_all_parameters request(params) end |
#restore_from_cluster_snapshot(options = {}) ⇒ Object
Parameters
-
:cluster_identifier - required - (String)
The identifier of the cluster that will be created from restoring the snapshot. Constraints: Must contain from 1 to 63 alphanumeric characters or hyphens. Alphabetic characters must be lowercase. First character must be a letter. Cannot end with a hyphen or contain two consecutive hyphens. Must be unique for all clusters within an AWS account.
-
:snapshot_identifier - required - (String)
The name of the snapshot from which to create the new cluster. This parameter isn't case sensitive. Example: my-snapshot-id
-
:snapshot_cluster_identifier - (String)
-
:port - (Integer)
The port number on which the cluster accepts connections. Default: The same port as the original cluster. Constraints: Must be between 1115 and 65535.
-
:availability_zone - (String)
The Amazon EC2 Availability Zone in which to restore the cluster. Default: A random, system-chosen Availability Zone. Example: us-east-1a
-
:allow_version_upgrade - (Boolean)
If true , upgrades can be applied during the maintenance window to the Amazon Redshift engine that is running on the cluster. Default: true
-
:cluster_subnet_group_name - (String)
The name of the subnet group where you want to cluster restored. A snapshot of cluster in VPC can be restored only in VPC. Therefore, you must provide subnet group name where you want the cluster restored.
-
:publicly_accessible - (Boolean)
If true , the cluster can be accessed from a public network.
-
:owner_account - (String)
The AWS customer account used to create or copy the snapshot. Required if you are restoring a snapshot you do not own, optional if you own the snapshot.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_RestoreFromClusterSnapshot.html
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 |
# File 'lib/fog/aws/requests/redshift/restore_from_cluster_snapshot.rb', line 41 def restore_from_cluster_snapshot( = {}) cluster_identifier = [:cluster_identifier] snapshot_identifier = [:snapshot_identifier] snapshot_cluster_identifier = [:snapshot_cluster_identifier] port = [:port] availability_zone = [:availability_zone] allow_version_upgrade = [:allow_version_upgrade] cluster_subnet_group_name = [:cluster_subnet_group_name] publicly_accessible = [:publicly_accessible] owner_account = [:owner_account] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::Cluster.new } params[:query]['Action'] = 'RestoreFromClusterSnapshot' params[:query]['ClusterIdentifier'] = cluster_identifier if cluster_identifier params[:query]['SnapshotIdentifier'] = snapshot_identifier if snapshot_identifier params[:query]['SnapshotClusterIdentifier'] = snapshot_cluster_identifier if snapshot_cluster_identifier params[:query]['Port'] = port if port params[:query]['AvailabilityZone'] = availability_zone if availability_zone params[:query]['AllowVersionUpgrade'] = allow_version_upgrade if allow_version_upgrade params[:query]['ClusterSubnetGroupName'] = cluster_subnet_group_name if cluster_subnet_group_name params[:query]['PubliclyAccessible'] = publicly_accessible if publicly_accessible params[:query]['OwnerAccount'] = owner_account if owner_account request(params) end |
#revoke_cluster_security_group_ingress(options = {}) ⇒ Object
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/fog/aws/requests/redshift/revoke_cluster_security_group_ingress.rb', line 28 def revoke_cluster_security_group_ingress( = {}) cluster_security_group_name = [:cluster_security_group_name] cidrip = [:cidrip] ec2_security_group_name = [:ec2_security_group_name] ec2_security_group_owner_id = [:ec2_security_group_owner_id] path = "/" params = { :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::RevokeClusterSecurityGroupIngress.new } params[:query]['Action'] = 'RevokeClusterSecurityGroupIngress' params[:query]['ClusterSecurityGroupName'] = cluster_security_group_name if cluster_security_group_name params[:query]['CIDRIP'] = cidrip if cidrip params[:query]['EC2SecurityGroupName'] = ec2_security_group_name if ec2_security_group_name params[:query]['EC2SecurityGroupOwnerId'] = ec2_security_group_owner_id if ec2_security_group_owner_id request(params) end |
#revoke_snapshot_access(options = {}) ⇒ Object
Parameters
-
:snapshot_identifier - required - (String)
The identifier of the snapshot that the account can no longer access.
-
:snapshot_cluster_identifier - (String)
-
:account_with_restore_access - required - (String)
The identifier of the AWS customer account that can no longer restore the specified snapshot.
See Also
docs.aws.amazon.com/redshift/latest/APIReference/API_RevokeSnapshotAccess.html
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/fog/aws/requests/redshift/revoke_snapshot_access.rb', line 18 def revoke_snapshot_access( = {}) snapshot_identifier = [:snapshot_identifier] snapshot_cluster_identifier = [:snapshot_cluster_identifier] account_with_restore_access = [:account_with_restore_access] path = "/" params = { :expects => 200, :headers => {}, :path => path, :method => :put, :query => {}, :parser => Fog::Parsers::Redshift::AWS::ClusterSnapshot.new } params[:query]['Action'] = 'RevokeSnapshotAccess' params[:query]['SnapshotIdentifier'] = snapshot_identifier if snapshot_identifier params[:query]['SnapshotClusterIdentifier'] = snapshot_cluster_identifier if snapshot_cluster_identifier params[:query]['AccountWithRestoreAccess'] = account_with_restore_access if account_with_restore_access request(params) end |