Skip to main content

monitors

Creates, updates, deletes or gets a monitor resource or lists monitors in a region

Overview

Namemonitors
TypeResource
DescriptionRepresents a monitor, which defines the monitoring boundaries for measurements that Internet Monitor publishes information about for an application
Idawscc.internetmonitor.monitors

Fields

NameDatatypeDescription
created_atstringThe date value in ISO 8601 format. The timezone is always UTC. (YYYY-MM-DDThh:mm:ssZ)
monitor_arnstring
monitor_namestring
linked_account_idstring
include_linked_accountsboolean
processing_statusstring
processing_status_infostring
resourcesarray
resources_to_addarray
resources_to_removearray
statusstring
tagsarray
max_city_networks_to_monitorinteger
traffic_percentage_to_monitorinteger
internet_measurements_log_deliveryobject
health_events_configobject
regionstringAWS region.

For more information, see AWS::InternetMonitor::Monitor.

Methods

NameResourceAccessible byRequired Params
create_resourcemonitorsINSERTMonitorName, region
delete_resourcemonitorsDELETEIdentifier, region
update_resourcemonitorsUPDATEIdentifier, PatchDocument, region
list_resourcesmonitors_list_onlySELECTregion
get_resourcemonitorsSELECTIdentifier, region

SELECT examples

Gets all properties from an individual monitor.

SELECT
region,
created_at,
modified_at,
monitor_arn,
monitor_name,
linked_account_id,
include_linked_accounts,
processing_status,
processing_status_info,
resources,
resources_to_add,
resources_to_remove,
status,
tags,
max_city_networks_to_monitor,
traffic_percentage_to_monitor,
internet_measurements_log_delivery,
health_events_config
FROM awscc.internetmonitor.monitors
WHERE
region = 'us-east-1' AND
Identifier = '{{ monitor_name }}';

INSERT example

Use the following StackQL query and manifest file to create a new monitor resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.internetmonitor.monitors (
MonitorName,
region
)
SELECT
'{{ monitor_name }}',
'{{ region }}';

UPDATE example

Use the following StackQL query and manifest file to update a monitor resource, using stack-deploy.

/*+ update */
UPDATE awscc.internetmonitor.monitors
SET PatchDocument = string('{{ {
"LinkedAccountId": linked_account_id,
"IncludeLinkedAccounts": include_linked_accounts,
"Resources": resources,
"ResourcesToAdd": resources_to_add,
"ResourcesToRemove": resources_to_remove,
"Status": status,
"Tags": tags,
"MaxCityNetworksToMonitor": max_city_networks_to_monitor,
"TrafficPercentageToMonitor": traffic_percentage_to_monitor,
"InternetMeasurementsLogDelivery": internet_measurements_log_delivery,
"HealthEventsConfig": health_events_config
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ monitor_name }}';

DELETE example

/*+ delete */
DELETE FROM awscc.internetmonitor.monitors
WHERE
Identifier = '{{ monitor_name }}' AND
region = 'us-east-1';

Permissions

To operate on the monitors resource, the following permissions are required:

internetmonitor:CreateMonitor,
internetmonitor:GetMonitor,
internetmonitor:TagResource,
internetmonitor:UntagResource,
logs:CreateLogDelivery,
logs:GetLogDelivery,
s3:GetBucketPolicy,
s3:PutBucketPolicy,
s3:ListBucket,
iam:PassRole