Skip to main content

scraper_logging_configurations

Creates, updates, deletes, gets or lists a scraper_logging_configurations resource.

Overview

Namescraper_logging_configurations
TypeResource
Idaws.amp.scraper_logging_configurations

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
logging_destinationobjectThe destination where scraper logs are sent.
modified_atstring (date-time)The date and time when the logging configuration was last modified.
scraper_componentsarrayThe list of scraper components configured for logging.
scraper_idstringA scraper ID. (pattern: <code>[0-9A-Za-z][-.0-9A-Z_a-z]*</code>)
statusobjectThe status of the scraper logging configuration.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
describe_scraper_logging_configurationselectscraper_id, regionDescribes the logging configuration for a Amazon Managed Service for Prometheus scraper.
update_scraper_logging_configurationupdatescraper_id, region, loggingDestinationUpdates the logging configuration for a Amazon Managed Service for Prometheus scraper.
delete_scraper_logging_configurationdeletescraper_id, regionclientTokenDeletes the logging configuration for a Amazon Managed Service for Prometheus scraper.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)
scraper_idstringThe ID of the scraper whose logging configuration will be deleted.
clientTokenstringA unique, case-sensitive identifier that you provide to ensure the request is processed exactly once.

SELECT examples

Describes the logging configuration for a Amazon Managed Service for Prometheus scraper.

SELECT
logging_destination,
modified_at,
scraper_components,
scraper_id,
status
FROM aws.amp.scraper_logging_configurations
WHERE scraper_id = '{{ scraper_id }}' -- required
AND region = '{{ region }}' -- required
;

UPDATE examples

Updates the logging configuration for a Amazon Managed Service for Prometheus scraper.

UPDATE aws.amp.scraper_logging_configurations
SET
loggingDestination = '{{ loggingDestination }}',
scraperComponents = '{{ scraperComponents }}'
WHERE
scraper_id = '{{ scraper_id }}' --required
AND region = '{{ region }}' --required
AND loggingDestination = '{{ loggingDestination }}' --required
RETURNING
status;

DELETE examples

Deletes the logging configuration for a Amazon Managed Service for Prometheus scraper.

DELETE FROM aws.amp.scraper_logging_configurations
WHERE scraper_id = '{{ scraper_id }}' --required
AND region = '{{ region }}' --required
AND clientToken = '{{ clientToken }}'
;