Amazon Redshift

2022/02/17 - Amazon Redshift - 11 updated api methods

Changes  SDK release for Cross region datasharing and cost-control for cross region datasharing

AssociateDataShareConsumer (updated) Link ¶
Changes (request, response)
Request
{'ConsumerRegion': 'string'}
Response
{'DataShareAssociations': {'ConsumerRegion': 'string'}}

From a datashare consumer account, associates a datashare with the account (AssociateEntireAccount) or the specified namespace (ConsumerArn). If you make this association, the consumer can consume the datashare.

See also: AWS API Documentation

Request Syntax

client.associate_data_share_consumer(
    DataShareArn='string',
    AssociateEntireAccount=True|False,
    ConsumerArn='string',
    ConsumerRegion='string'
)
type DataShareArn

string

param DataShareArn

[REQUIRED]

The Amazon Resource Name (ARN) of the datashare that the consumer is to use with the account or the namespace.

type AssociateEntireAccount

boolean

param AssociateEntireAccount

A value that specifies whether the datashare is associated with the entire account.

type ConsumerArn

string

param ConsumerArn

The Amazon Resource Name (ARN) of the consumer that is associated with the datashare.

type ConsumerRegion

string

param ConsumerRegion

From a datashare consumer account, associates a datashare with all existing and future namespaces in the specified Amazon Web Services Region.

rtype

dict

returns

Response Syntax

{
    'DataShareArn': 'string',
    'ProducerArn': 'string',
    'AllowPubliclyAccessibleConsumers': True|False,
    'DataShareAssociations': [
        {
            'ConsumerIdentifier': 'string',
            'Status': 'ACTIVE'|'PENDING_AUTHORIZATION'|'AUTHORIZED'|'DEAUTHORIZED'|'REJECTED'|'AVAILABLE',
            'ConsumerRegion': 'string',
            'CreatedDate': datetime(2015, 1, 1),
            'StatusChangeDate': datetime(2015, 1, 1)
        },
    ],
    'ManagedBy': 'string'
}

Response Structure

  • (dict) --

    • DataShareArn (string) --

      An Amazon Resource Name (ARN) that references the datashare that is owned by a specific namespace of the producer cluster. A datashare ARN is in the arn:aws:redshift:{region}:{account-id}:{datashare}:{namespace-guid}/{datashare-name} format.

    • ProducerArn (string) --

      The Amazon Resource Name (ARN) of the producer.

    • AllowPubliclyAccessibleConsumers (boolean) --

      A value that specifies whether the datashare can be shared to a publicly accessible cluster.

    • DataShareAssociations (list) --

      A value that specifies when the datashare has an association between a producer and data consumers.

      • (dict) --

        The association of a datashare from a producer account with a data consumer.

        • ConsumerIdentifier (string) --

          The name of the consumer accounts that have an association with a producer datashare.

        • Status (string) --

          The status of the datashare that is associated.

        • ConsumerRegion (string) --

          The Amazon Web Services Region of the consumer accounts that have an association with a producer datashare.

        • CreatedDate (datetime) --

          The creation date of the datashare that is associated.

        • StatusChangeDate (datetime) --

          The status change data of the datashare that is associated.

    • ManagedBy (string) --

      The identifier of a datashare to show its managing entity.

AuthorizeDataShare (updated) Link ¶
Changes (response)
{'DataShareAssociations': {'ConsumerRegion': 'string'}}

From a data producer account, authorizes the sharing of a datashare with one or more consumer accounts or managing entities. To authorize a datashare for a data consumer, the producer account must have the correct access privileges.

See also: AWS API Documentation

Request Syntax

client.authorize_data_share(
    DataShareArn='string',
    ConsumerIdentifier='string'
)
type DataShareArn

string

param DataShareArn

[REQUIRED]

The Amazon Resource Name (ARN) of the datashare that producers are to authorize sharing for.

type ConsumerIdentifier

string

param ConsumerIdentifier

[REQUIRED]

The identifier of the data consumer that is authorized to access the datashare. This identifier is an Amazon Web Services account ID or a keyword, such as ADX.

rtype

dict

returns

Response Syntax

{
    'DataShareArn': 'string',
    'ProducerArn': 'string',
    'AllowPubliclyAccessibleConsumers': True|False,
    'DataShareAssociations': [
        {
            'ConsumerIdentifier': 'string',
            'Status': 'ACTIVE'|'PENDING_AUTHORIZATION'|'AUTHORIZED'|'DEAUTHORIZED'|'REJECTED'|'AVAILABLE',
            'ConsumerRegion': 'string',
            'CreatedDate': datetime(2015, 1, 1),
            'StatusChangeDate': datetime(2015, 1, 1)
        },
    ],
    'ManagedBy': 'string'
}

Response Structure

  • (dict) --

    • DataShareArn (string) --

      An Amazon Resource Name (ARN) that references the datashare that is owned by a specific namespace of the producer cluster. A datashare ARN is in the arn:aws:redshift:{region}:{account-id}:{datashare}:{namespace-guid}/{datashare-name} format.

    • ProducerArn (string) --

      The Amazon Resource Name (ARN) of the producer.

    • AllowPubliclyAccessibleConsumers (boolean) --

      A value that specifies whether the datashare can be shared to a publicly accessible cluster.

    • DataShareAssociations (list) --

      A value that specifies when the datashare has an association between a producer and data consumers.

      • (dict) --

        The association of a datashare from a producer account with a data consumer.

        • ConsumerIdentifier (string) --

          The name of the consumer accounts that have an association with a producer datashare.

        • Status (string) --

          The status of the datashare that is associated.

        • ConsumerRegion (string) --

          The Amazon Web Services Region of the consumer accounts that have an association with a producer datashare.

        • CreatedDate (datetime) --

          The creation date of the datashare that is associated.

        • StatusChangeDate (datetime) --

          The status change data of the datashare that is associated.

    • ManagedBy (string) --

      The identifier of a datashare to show its managing entity.

CreateUsageLimit (updated) Link ¶
Changes (both)
{'FeatureType': {'cross-region-datasharing'}}

Creates a usage limit for a specified Amazon Redshift feature on a cluster. The usage limit is identified by the returned usage limit identifier.

See also: AWS API Documentation

Request Syntax

client.create_usage_limit(
    ClusterIdentifier='string',
    FeatureType='spectrum'|'concurrency-scaling'|'cross-region-datasharing',
    LimitType='time'|'data-scanned',
    Amount=123,
    Period='daily'|'weekly'|'monthly',
    BreachAction='log'|'emit-metric'|'disable',
    Tags=[
        {
            'Key': 'string',
            'Value': 'string'
        },
    ]
)
type ClusterIdentifier

string

param ClusterIdentifier

[REQUIRED]

The identifier of the cluster that you want to limit usage.

type FeatureType

string

param FeatureType

[REQUIRED]

The Amazon Redshift feature that you want to limit.

type LimitType

string

param LimitType

[REQUIRED]

The type of limit. Depending on the feature type, this can be based on a time duration or data size. If FeatureType is spectrum , then LimitType must be data-scanned . If FeatureType is concurrency-scaling , then LimitType must be time . If FeatureType is cross-region-datasharing , then LimitType must be data-scanned .

type Amount

integer

param Amount

[REQUIRED]

The limit amount. If time-based, this amount is in minutes. If data-based, this amount is in terabytes (TB). The value must be a positive number.

type Period

string

param Period

The time period that the amount applies to. A weekly period begins on Sunday. The default is monthly .

type BreachAction

string

param BreachAction

The action that Amazon Redshift takes when the limit is reached. The default is log. For more information about this parameter, see UsageLimit .

type Tags

list

param Tags

A list of tag instances.

  • (dict) --

    A tag consisting of a name/value pair for a resource.

    • Key (string) --

      The key, or name, for the resource tag.

    • Value (string) --

      The value for the resource tag.

rtype

dict

returns

Response Syntax

{
    'UsageLimitId': 'string',
    'ClusterIdentifier': 'string',
    'FeatureType': 'spectrum'|'concurrency-scaling'|'cross-region-datasharing',
    'LimitType': 'time'|'data-scanned',
    'Amount': 123,
    'Period': 'daily'|'weekly'|'monthly',
    'BreachAction': 'log'|'emit-metric'|'disable',
    'Tags': [
        {
            'Key': 'string',
            'Value': 'string'
        },
    ]
}

Response Structure

  • (dict) --

    Describes a usage limit object for a cluster.

    • UsageLimitId (string) --

      The identifier of the usage limit.

    • ClusterIdentifier (string) --

      The identifier of the cluster with a usage limit.

    • FeatureType (string) --

      The Amazon Redshift feature to which the limit applies.

    • LimitType (string) --

      The type of limit. Depending on the feature type, this can be based on a time duration or data size.

    • Amount (integer) --

      The limit amount. If time-based, this amount is in minutes. If data-based, this amount is in terabytes (TB).

    • Period (string) --

      The time period that the amount applies to. A weekly period begins on Sunday. The default is monthly .

    • BreachAction (string) --

      The action that Amazon Redshift takes when the limit is reached. Possible values are:

      • log - To log an event in a system table. The default is log.

      • emit-metric - To emit CloudWatch metrics.

      • disable - To disable the feature until the next usage period begins.

    • Tags (list) --

      A list of tag instances.

      • (dict) --

        A tag consisting of a name/value pair for a resource.

        • Key (string) --

          The key, or name, for the resource tag.

        • Value (string) --

          The value for the resource tag.

DeauthorizeDataShare (updated) Link ¶
Changes (response)
{'DataShareAssociations': {'ConsumerRegion': 'string'}}

From the producer account, removes authorization from the specified datashare.

See also: AWS API Documentation

Request Syntax

client.deauthorize_data_share(
    DataShareArn='string',
    ConsumerIdentifier='string'
)
type DataShareArn

string

param DataShareArn

[REQUIRED]

The Amazon Resource Name (ARN) of the datashare to remove authorization from.

type ConsumerIdentifier

string

param ConsumerIdentifier

[REQUIRED]

The identifier of the data consumer that is to have authorization removed from the datashare. This identifier is an Amazon Web Services account ID or a keyword, such as ADX.

rtype

dict

returns

Response Syntax

{
    'DataShareArn': 'string',
    'ProducerArn': 'string',
    'AllowPubliclyAccessibleConsumers': True|False,
    'DataShareAssociations': [
        {
            'ConsumerIdentifier': 'string',
            'Status': 'ACTIVE'|'PENDING_AUTHORIZATION'|'AUTHORIZED'|'DEAUTHORIZED'|'REJECTED'|'AVAILABLE',
            'ConsumerRegion': 'string',
            'CreatedDate': datetime(2015, 1, 1),
            'StatusChangeDate': datetime(2015, 1, 1)
        },
    ],
    'ManagedBy': 'string'
}

Response Structure

  • (dict) --

    • DataShareArn (string) --

      An Amazon Resource Name (ARN) that references the datashare that is owned by a specific namespace of the producer cluster. A datashare ARN is in the arn:aws:redshift:{region}:{account-id}:{datashare}:{namespace-guid}/{datashare-name} format.

    • ProducerArn (string) --

      The Amazon Resource Name (ARN) of the producer.

    • AllowPubliclyAccessibleConsumers (boolean) --

      A value that specifies whether the datashare can be shared to a publicly accessible cluster.

    • DataShareAssociations (list) --

      A value that specifies when the datashare has an association between a producer and data consumers.

      • (dict) --

        The association of a datashare from a producer account with a data consumer.

        • ConsumerIdentifier (string) --

          The name of the consumer accounts that have an association with a producer datashare.

        • Status (string) --

          The status of the datashare that is associated.

        • ConsumerRegion (string) --

          The Amazon Web Services Region of the consumer accounts that have an association with a producer datashare.

        • CreatedDate (datetime) --

          The creation date of the datashare that is associated.

        • StatusChangeDate (datetime) --

          The status change data of the datashare that is associated.

    • ManagedBy (string) --

      The identifier of a datashare to show its managing entity.

DescribeDataShares (updated) Link ¶
Changes (response)
{'DataShares': {'DataShareAssociations': {'ConsumerRegion': 'string'}}}

Shows the status of any inbound or outbound datashares available in the specified account.

See also: AWS API Documentation

Request Syntax

client.describe_data_shares(
    DataShareArn='string',
    MaxRecords=123,
    Marker='string'
)
type DataShareArn

string

param DataShareArn

The identifier of the datashare to describe details of.

type MaxRecords

integer

param MaxRecords

The maximum number of response records to return in each call. If the number of remaining response records exceeds the specified MaxRecords value, a value is returned in a marker field of the response. You can retrieve the next set of records by retrying the command with the returned marker value.

type Marker

string

param Marker

An optional parameter that specifies the starting point to return a set of response records. When the results of a DescribeDataShares request exceed the value specified in MaxRecords , Amazon Web Services returns a value in the Marker field of the response. You can retrieve the next set of response records by providing the returned marker value in the Marker parameter and retrying the request.

rtype

dict

returns

Response Syntax

{
    'DataShares': [
        {
            'DataShareArn': 'string',
            'ProducerArn': 'string',
            'AllowPubliclyAccessibleConsumers': True|False,
            'DataShareAssociations': [
                {
                    'ConsumerIdentifier': 'string',
                    'Status': 'ACTIVE'|'PENDING_AUTHORIZATION'|'AUTHORIZED'|'DEAUTHORIZED'|'REJECTED'|'AVAILABLE',
                    'ConsumerRegion': 'string',
                    'CreatedDate': datetime(2015, 1, 1),
                    'StatusChangeDate': datetime(2015, 1, 1)
                },
            ],
            'ManagedBy': 'string'
        },
    ],
    'Marker': 'string'
}

Response Structure

  • (dict) --

    • DataShares (list) --

      The results returned from describing datashares.

      • (dict) --

        • DataShareArn (string) --

          An Amazon Resource Name (ARN) that references the datashare that is owned by a specific namespace of the producer cluster. A datashare ARN is in the arn:aws:redshift:{region}:{account-id}:{datashare}:{namespace-guid}/{datashare-name} format.

        • ProducerArn (string) --

          The Amazon Resource Name (ARN) of the producer.

        • AllowPubliclyAccessibleConsumers (boolean) --

          A value that specifies whether the datashare can be shared to a publicly accessible cluster.

        • DataShareAssociations (list) --

          A value that specifies when the datashare has an association between a producer and data consumers.

          • (dict) --

            The association of a datashare from a producer account with a data consumer.

            • ConsumerIdentifier (string) --

              The name of the consumer accounts that have an association with a producer datashare.

            • Status (string) --

              The status of the datashare that is associated.

            • ConsumerRegion (string) --

              The Amazon Web Services Region of the consumer accounts that have an association with a producer datashare.

            • CreatedDate (datetime) --

              The creation date of the datashare that is associated.

            • StatusChangeDate (datetime) --

              The status change data of the datashare that is associated.

        • ManagedBy (string) --

          The identifier of a datashare to show its managing entity.

    • Marker (string) --

      An optional parameter that specifies the starting point to return a set of response records. When the results of a DescribeDataShares request exceed the value specified in MaxRecords , Amazon Web Services returns a value in the Marker field of the response. You can retrieve the next set of response records by providing the returned marker value in the Marker parameter and retrying the request.

DescribeDataSharesForConsumer (updated) Link ¶
Changes (response)
{'DataShares': {'DataShareAssociations': {'ConsumerRegion': 'string'}}}

Returns a list of datashares where the account identifier being called is a consumer account identifier.

See also: AWS API Documentation

Request Syntax

client.describe_data_shares_for_consumer(
    ConsumerArn='string',
    Status='ACTIVE'|'AVAILABLE',
    MaxRecords=123,
    Marker='string'
)
type ConsumerArn

string

param ConsumerArn

The Amazon Resource Name (ARN) of the consumer that returns in the list of datashares.

type Status

string

param Status

An identifier giving the status of a datashare in the consumer cluster. If this field is specified, Amazon Redshift returns the list of datashares that have the specified status.

type MaxRecords

integer

param MaxRecords

The maximum number of response records to return in each call. If the number of remaining response records exceeds the specified MaxRecords value, a value is returned in a marker field of the response. You can retrieve the next set of records by retrying the command with the returned marker value.

type Marker

string

param Marker

An optional parameter that specifies the starting point to return a set of response records. When the results of a DescribeDataSharesForConsumer request exceed the value specified in MaxRecords , Amazon Web Services returns a value in the Marker field of the response. You can retrieve the next set of response records by providing the returned marker value in the Marker parameter and retrying the request.

rtype

dict

returns

Response Syntax

{
    'DataShares': [
        {
            'DataShareArn': 'string',
            'ProducerArn': 'string',
            'AllowPubliclyAccessibleConsumers': True|False,
            'DataShareAssociations': [
                {
                    'ConsumerIdentifier': 'string',
                    'Status': 'ACTIVE'|'PENDING_AUTHORIZATION'|'AUTHORIZED'|'DEAUTHORIZED'|'REJECTED'|'AVAILABLE',
                    'ConsumerRegion': 'string',
                    'CreatedDate': datetime(2015, 1, 1),
                    'StatusChangeDate': datetime(2015, 1, 1)
                },
            ],
            'ManagedBy': 'string'
        },
    ],
    'Marker': 'string'
}

Response Structure

  • (dict) --

    • DataShares (list) --

      Shows the results of datashares available for consumers.

      • (dict) --

        • DataShareArn (string) --

          An Amazon Resource Name (ARN) that references the datashare that is owned by a specific namespace of the producer cluster. A datashare ARN is in the arn:aws:redshift:{region}:{account-id}:{datashare}:{namespace-guid}/{datashare-name} format.

        • ProducerArn (string) --

          The Amazon Resource Name (ARN) of the producer.

        • AllowPubliclyAccessibleConsumers (boolean) --

          A value that specifies whether the datashare can be shared to a publicly accessible cluster.

        • DataShareAssociations (list) --

          A value that specifies when the datashare has an association between a producer and data consumers.

          • (dict) --

            The association of a datashare from a producer account with a data consumer.

            • ConsumerIdentifier (string) --

              The name of the consumer accounts that have an association with a producer datashare.

            • Status (string) --

              The status of the datashare that is associated.

            • ConsumerRegion (string) --

              The Amazon Web Services Region of the consumer accounts that have an association with a producer datashare.

            • CreatedDate (datetime) --

              The creation date of the datashare that is associated.

            • StatusChangeDate (datetime) --

              The status change data of the datashare that is associated.

        • ManagedBy (string) --

          The identifier of a datashare to show its managing entity.

    • Marker (string) --

      An optional parameter that specifies the starting point to return a set of response records. When the results of a DescribeDataSharesForConsumer request exceed the value specified in MaxRecords , Amazon Web Services returns a value in the Marker field of the response. You can retrieve the next set of response records by providing the returned marker value in the Marker parameter and retrying the request.

DescribeDataSharesForProducer (updated) Link ¶
Changes (response)
{'DataShares': {'DataShareAssociations': {'ConsumerRegion': 'string'}}}

Returns a list of datashares when the account identifier being called is a producer account identifier.

See also: AWS API Documentation

Request Syntax

client.describe_data_shares_for_producer(
    ProducerArn='string',
    Status='ACTIVE'|'AUTHORIZED'|'PENDING_AUTHORIZATION'|'DEAUTHORIZED'|'REJECTED',
    MaxRecords=123,
    Marker='string'
)
type ProducerArn

string

param ProducerArn

The Amazon Resource Name (ARN) of the producer that returns in the list of datashares.

type Status

string

param Status

An identifier giving the status of a datashare in the producer. If this field is specified, Amazon Redshift returns the list of datashares that have the specified status.

type MaxRecords

integer

param MaxRecords

The maximum number of response records to return in each call. If the number of remaining response records exceeds the specified MaxRecords value, a value is returned in a marker field of the response. You can retrieve the next set of records by retrying the command with the returned marker value.

type Marker

string

param Marker

An optional parameter that specifies the starting point to return a set of response records. When the results of a DescribeDataSharesForProducer request exceed the value specified in MaxRecords , Amazon Web Services returns a value in the Marker field of the response. You can retrieve the next set of response records by providing the returned marker value in the Marker parameter and retrying the request.

rtype

dict

returns

Response Syntax

{
    'DataShares': [
        {
            'DataShareArn': 'string',
            'ProducerArn': 'string',
            'AllowPubliclyAccessibleConsumers': True|False,
            'DataShareAssociations': [
                {
                    'ConsumerIdentifier': 'string',
                    'Status': 'ACTIVE'|'PENDING_AUTHORIZATION'|'AUTHORIZED'|'DEAUTHORIZED'|'REJECTED'|'AVAILABLE',
                    'ConsumerRegion': 'string',
                    'CreatedDate': datetime(2015, 1, 1),
                    'StatusChangeDate': datetime(2015, 1, 1)
                },
            ],
            'ManagedBy': 'string'
        },
    ],
    'Marker': 'string'
}

Response Structure

  • (dict) --

    • DataShares (list) --

      Shows the results of datashares available for producers.

      • (dict) --

        • DataShareArn (string) --

          An Amazon Resource Name (ARN) that references the datashare that is owned by a specific namespace of the producer cluster. A datashare ARN is in the arn:aws:redshift:{region}:{account-id}:{datashare}:{namespace-guid}/{datashare-name} format.

        • ProducerArn (string) --

          The Amazon Resource Name (ARN) of the producer.

        • AllowPubliclyAccessibleConsumers (boolean) --

          A value that specifies whether the datashare can be shared to a publicly accessible cluster.

        • DataShareAssociations (list) --

          A value that specifies when the datashare has an association between a producer and data consumers.

          • (dict) --

            The association of a datashare from a producer account with a data consumer.

            • ConsumerIdentifier (string) --

              The name of the consumer accounts that have an association with a producer datashare.

            • Status (string) --

              The status of the datashare that is associated.

            • ConsumerRegion (string) --

              The Amazon Web Services Region of the consumer accounts that have an association with a producer datashare.

            • CreatedDate (datetime) --

              The creation date of the datashare that is associated.

            • StatusChangeDate (datetime) --

              The status change data of the datashare that is associated.

        • ManagedBy (string) --

          The identifier of a datashare to show its managing entity.

    • Marker (string) --

      An optional parameter that specifies the starting point to return a set of response records. When the results of a DescribeDataSharesForProducer request exceed the value specified in MaxRecords , Amazon Web Services returns a value in the Marker field of the response. You can retrieve the next set of response records by providing the returned marker value in the Marker parameter and retrying the request.

DescribeUsageLimits (updated) Link ¶
Changes (request, response)
Request
{'FeatureType': {'cross-region-datasharing'}}
Response
{'UsageLimits': {'FeatureType': {'cross-region-datasharing'}}}

Shows usage limits on a cluster. Results are filtered based on the combination of input usage limit identifier, cluster identifier, and feature type parameters:

  • If usage limit identifier, cluster identifier, and feature type are not provided, then all usage limit objects for the current account in the current region are returned.

  • If usage limit identifier is provided, then the corresponding usage limit object is returned.

  • If cluster identifier is provided, then all usage limit objects for the specified cluster are returned.

  • If cluster identifier and feature type are provided, then all usage limit objects for the combination of cluster and feature are returned.

See also: AWS API Documentation

Request Syntax

client.describe_usage_limits(
    UsageLimitId='string',
    ClusterIdentifier='string',
    FeatureType='spectrum'|'concurrency-scaling'|'cross-region-datasharing',
    MaxRecords=123,
    Marker='string',
    TagKeys=[
        'string',
    ],
    TagValues=[
        'string',
    ]
)
type UsageLimitId

string

param UsageLimitId

The identifier of the usage limit to describe.

type ClusterIdentifier

string

param ClusterIdentifier

The identifier of the cluster for which you want to describe usage limits.

type FeatureType

string

param FeatureType

The feature type for which you want to describe usage limits.

type MaxRecords

integer

param MaxRecords

The maximum number of response records to return in each call. If the number of remaining response records exceeds the specified MaxRecords value, a value is returned in a marker field of the response. You can retrieve the next set of records by retrying the command with the returned marker value.

Default: 100

Constraints: minimum 20, maximum 100.

type Marker

string

param Marker

An optional parameter that specifies the starting point to return a set of response records. When the results of a DescribeUsageLimits request exceed the value specified in MaxRecords , Amazon Web Services returns a value in the Marker field of the response. You can retrieve the next set of response records by providing the returned marker value in the Marker parameter and retrying the request.

type TagKeys

list

param TagKeys

A tag key or keys for which you want to return all matching usage limit objects that are associated with the specified key or keys. For example, suppose that you have parameter groups that are tagged with keys called owner and environment . If you specify both of these tag keys in the request, Amazon Redshift returns a response with the usage limit objects have either or both of these tag keys associated with them.

  • (string) --

type TagValues

list

param TagValues

A tag value or values for which you want to return all matching usage limit objects that are associated with the specified tag value or values. For example, suppose that you have parameter groups that are tagged with values called admin and test . If you specify both of these tag values in the request, Amazon Redshift returns a response with the usage limit objects that have either or both of these tag values associated with them.

  • (string) --

rtype

dict

returns

Response Syntax

{
    'UsageLimits': [
        {
            'UsageLimitId': 'string',
            'ClusterIdentifier': 'string',
            'FeatureType': 'spectrum'|'concurrency-scaling'|'cross-region-datasharing',
            'LimitType': 'time'|'data-scanned',
            'Amount': 123,
            'Period': 'daily'|'weekly'|'monthly',
            'BreachAction': 'log'|'emit-metric'|'disable',
            'Tags': [
                {
                    'Key': 'string',
                    'Value': 'string'
                },
            ]
        },
    ],
    'Marker': 'string'
}

Response Structure

  • (dict) --

    • UsageLimits (list) --

      Contains the output from the DescribeUsageLimits action.

      • (dict) --

        Describes a usage limit object for a cluster.

        • UsageLimitId (string) --

          The identifier of the usage limit.

        • ClusterIdentifier (string) --

          The identifier of the cluster with a usage limit.

        • FeatureType (string) --

          The Amazon Redshift feature to which the limit applies.

        • LimitType (string) --

          The type of limit. Depending on the feature type, this can be based on a time duration or data size.

        • Amount (integer) --

          The limit amount. If time-based, this amount is in minutes. If data-based, this amount is in terabytes (TB).

        • Period (string) --

          The time period that the amount applies to. A weekly period begins on Sunday. The default is monthly .

        • BreachAction (string) --

          The action that Amazon Redshift takes when the limit is reached. Possible values are:

          • log - To log an event in a system table. The default is log.

          • emit-metric - To emit CloudWatch metrics.

          • disable - To disable the feature until the next usage period begins.

        • Tags (list) --

          A list of tag instances.

          • (dict) --

            A tag consisting of a name/value pair for a resource.

            • Key (string) --

              The key, or name, for the resource tag.

            • Value (string) --

              The value for the resource tag.

    • Marker (string) --

      A value that indicates the starting point for the next set of response records in a subsequent request. If a value is returned in a response, you can retrieve the next set of records by providing this returned marker value in the Marker parameter and retrying the command. If the Marker field is empty, all response records have been retrieved for the request.

DisassociateDataShareConsumer (updated) Link ¶
Changes (request, response)
Request
{'ConsumerRegion': 'string'}
Response
{'DataShareAssociations': {'ConsumerRegion': 'string'}}

From a consumer account, remove association for the specified datashare.

See also: AWS API Documentation

Request Syntax

client.disassociate_data_share_consumer(
    DataShareArn='string',
    DisassociateEntireAccount=True|False,
    ConsumerArn='string',
    ConsumerRegion='string'
)
type DataShareArn

string

param DataShareArn

[REQUIRED]

The Amazon Resource Name (ARN) of the datashare to remove association for.

type DisassociateEntireAccount

boolean

param DisassociateEntireAccount

A value that specifies whether association for the datashare is removed from the entire account.

type ConsumerArn

string

param ConsumerArn

The Amazon Resource Name (ARN) of the consumer that association for the datashare is removed from.

type ConsumerRegion

string

param ConsumerRegion

From a datashare consumer account, removes association of a datashare from all the existing and future namespaces in the specified Amazon Web Services Region.

rtype

dict

returns

Response Syntax

{
    'DataShareArn': 'string',
    'ProducerArn': 'string',
    'AllowPubliclyAccessibleConsumers': True|False,
    'DataShareAssociations': [
        {
            'ConsumerIdentifier': 'string',
            'Status': 'ACTIVE'|'PENDING_AUTHORIZATION'|'AUTHORIZED'|'DEAUTHORIZED'|'REJECTED'|'AVAILABLE',
            'ConsumerRegion': 'string',
            'CreatedDate': datetime(2015, 1, 1),
            'StatusChangeDate': datetime(2015, 1, 1)
        },
    ],
    'ManagedBy': 'string'
}

Response Structure

  • (dict) --

    • DataShareArn (string) --

      An Amazon Resource Name (ARN) that references the datashare that is owned by a specific namespace of the producer cluster. A datashare ARN is in the arn:aws:redshift:{region}:{account-id}:{datashare}:{namespace-guid}/{datashare-name} format.

    • ProducerArn (string) --

      The Amazon Resource Name (ARN) of the producer.

    • AllowPubliclyAccessibleConsumers (boolean) --

      A value that specifies whether the datashare can be shared to a publicly accessible cluster.

    • DataShareAssociations (list) --

      A value that specifies when the datashare has an association between a producer and data consumers.

      • (dict) --

        The association of a datashare from a producer account with a data consumer.

        • ConsumerIdentifier (string) --

          The name of the consumer accounts that have an association with a producer datashare.

        • Status (string) --

          The status of the datashare that is associated.

        • ConsumerRegion (string) --

          The Amazon Web Services Region of the consumer accounts that have an association with a producer datashare.

        • CreatedDate (datetime) --

          The creation date of the datashare that is associated.

        • StatusChangeDate (datetime) --

          The status change data of the datashare that is associated.

    • ManagedBy (string) --

      The identifier of a datashare to show its managing entity.

ModifyUsageLimit (updated) Link ¶
Changes (response)
{'FeatureType': {'cross-region-datasharing'}}

Modifies a usage limit in a cluster. You can't modify the feature type or period of a usage limit.

See also: AWS API Documentation

Request Syntax

client.modify_usage_limit(
    UsageLimitId='string',
    Amount=123,
    BreachAction='log'|'emit-metric'|'disable'
)
type UsageLimitId

string

param UsageLimitId

[REQUIRED]

The identifier of the usage limit to modify.

type Amount

integer

param Amount

The new limit amount. For more information about this parameter, see UsageLimit .

type BreachAction

string

param BreachAction

The new action that Amazon Redshift takes when the limit is reached. For more information about this parameter, see UsageLimit .

rtype

dict

returns

Response Syntax

{
    'UsageLimitId': 'string',
    'ClusterIdentifier': 'string',
    'FeatureType': 'spectrum'|'concurrency-scaling'|'cross-region-datasharing',
    'LimitType': 'time'|'data-scanned',
    'Amount': 123,
    'Period': 'daily'|'weekly'|'monthly',
    'BreachAction': 'log'|'emit-metric'|'disable',
    'Tags': [
        {
            'Key': 'string',
            'Value': 'string'
        },
    ]
}

Response Structure

  • (dict) --

    Describes a usage limit object for a cluster.

    • UsageLimitId (string) --

      The identifier of the usage limit.

    • ClusterIdentifier (string) --

      The identifier of the cluster with a usage limit.

    • FeatureType (string) --

      The Amazon Redshift feature to which the limit applies.

    • LimitType (string) --

      The type of limit. Depending on the feature type, this can be based on a time duration or data size.

    • Amount (integer) --

      The limit amount. If time-based, this amount is in minutes. If data-based, this amount is in terabytes (TB).

    • Period (string) --

      The time period that the amount applies to. A weekly period begins on Sunday. The default is monthly .

    • BreachAction (string) --

      The action that Amazon Redshift takes when the limit is reached. Possible values are:

      • log - To log an event in a system table. The default is log.

      • emit-metric - To emit CloudWatch metrics.

      • disable - To disable the feature until the next usage period begins.

    • Tags (list) --

      A list of tag instances.

      • (dict) --

        A tag consisting of a name/value pair for a resource.

        • Key (string) --

          The key, or name, for the resource tag.

        • Value (string) --

          The value for the resource tag.

RejectDataShare (updated) Link ¶
Changes (response)
{'DataShareAssociations': {'ConsumerRegion': 'string'}}

From the consumer account, rejects the specified datashare.

See also: AWS API Documentation

Request Syntax

client.reject_data_share(
    DataShareArn='string'
)
type DataShareArn

string

param DataShareArn

[REQUIRED]

The Amazon Resource Name (ARN) of the datashare to reject.

rtype

dict

returns

Response Syntax

{
    'DataShareArn': 'string',
    'ProducerArn': 'string',
    'AllowPubliclyAccessibleConsumers': True|False,
    'DataShareAssociations': [
        {
            'ConsumerIdentifier': 'string',
            'Status': 'ACTIVE'|'PENDING_AUTHORIZATION'|'AUTHORIZED'|'DEAUTHORIZED'|'REJECTED'|'AVAILABLE',
            'ConsumerRegion': 'string',
            'CreatedDate': datetime(2015, 1, 1),
            'StatusChangeDate': datetime(2015, 1, 1)
        },
    ],
    'ManagedBy': 'string'
}

Response Structure

  • (dict) --

    • DataShareArn (string) --

      An Amazon Resource Name (ARN) that references the datashare that is owned by a specific namespace of the producer cluster. A datashare ARN is in the arn:aws:redshift:{region}:{account-id}:{datashare}:{namespace-guid}/{datashare-name} format.

    • ProducerArn (string) --

      The Amazon Resource Name (ARN) of the producer.

    • AllowPubliclyAccessibleConsumers (boolean) --

      A value that specifies whether the datashare can be shared to a publicly accessible cluster.

    • DataShareAssociations (list) --

      A value that specifies when the datashare has an association between a producer and data consumers.

      • (dict) --

        The association of a datashare from a producer account with a data consumer.

        • ConsumerIdentifier (string) --

          The name of the consumer accounts that have an association with a producer datashare.

        • Status (string) --

          The status of the datashare that is associated.

        • ConsumerRegion (string) --

          The Amazon Web Services Region of the consumer accounts that have an association with a producer datashare.

        • CreatedDate (datetime) --

          The creation date of the datashare that is associated.

        • StatusChangeDate (datetime) --

          The status change data of the datashare that is associated.

    • ManagedBy (string) --

      The identifier of a datashare to show its managing entity.