network_performance_metric_subscriptions
Used to retrieve a list of network_performance_metric_subscriptions
in a region or to create or delete a network_performance_metric_subscriptions
resource, use network_performance_metric_subscription
to read or update an individual resource.
Overview
Name | network_performance_metric_subscriptions |
Type | Resource |
Description | Resource Type definition for AWS::EC2::NetworkPerformanceMetricSubscription |
Id | aws.ec2.network_performance_metric_subscriptions |
Fields
Name | Datatype | Description |
---|---|---|
source | string | The starting Region or Availability Zone for metric to subscribe to. |
destination | string | The target Region or Availability Zone for the metric to subscribe to. |
metric | string | The metric type to subscribe to. |
statistic | string | The statistic to subscribe to. |
region | string | AWS region. |
Methods
Name | Accessible by | Required Params |
---|---|---|
create_resource | INSERT | Source, Destination, Metric, Statistic, region |
delete_resource | DELETE | data__Identifier, region |
list_resource | SELECT | region |
SELECT
Example
SELECT
region,
source,
destination,
metric,
statistic
FROM aws.ec2.network_performance_metric_subscriptions
WHERE region = 'us-east-1';
INSERT
Example
Use the following StackQL query and manifest file to create a new network_performance_metric_subscription
resource, using stack-deploy
.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO aws.ec2.network_performance_metric_subscriptions (
Source,
Destination,
Metric,
Statistic,
region
)
SELECT
'{{ Source }}',
'{{ Destination }}',
'{{ Metric }}',
'{{ Statistic }}',
'{{ region }}';
/*+ create */
INSERT INTO aws.ec2.network_performance_metric_subscriptions (
Source,
Destination,
Metric,
Statistic,
region
)
SELECT
'{{ Source }}',
'{{ Destination }}',
'{{ Metric }}',
'{{ Statistic }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: network_performance_metric_subscription
props:
- name: Source
value: '{{ Source }}'
- name: Destination
value: '{{ Destination }}'
- name: Metric
value: '{{ Metric }}'
- name: Statistic
value: '{{ Statistic }}'
DELETE
Example
/*+ delete */
DELETE FROM aws.ec2.network_performance_metric_subscriptions
WHERE data__Identifier = '<Source|Destination|Metric|Statistic>'
AND region = 'us-east-1';
Permissions
To operate on the network_performance_metric_subscriptions
resource, the following permissions are required:
Create
ec2:DescribeAwsNetworkPerformanceMetricSubscriptions,
ec2:EnableAwsNetworkPerformanceMetricSubscription
Delete
ec2:DescribeAwsNetworkPerformanceMetricSubscriptions,
ec2:DisableAwsNetworkPerformanceMetricSubscription
List
ec2:DescribeAwsNetworkPerformanceMetricSubscriptions