UpdateMetricSet - Amazon Lookout for Metrics

UpdateMetricSet

Updates a dataset.

Request Syntax

POST /UpdateMetricSet HTTP/1.1 Content-type: application/json { "DimensionList": [ "string" ], "MetricList": [ { "AggregationFunction": "string", "MetricName": "string", "Namespace": "string" } ], "MetricSetArn": "string", "MetricSetDescription": "string", "MetricSetFrequency": "string", "MetricSource": { "AppFlowConfig": { "FlowName": "string", "RoleArn": "string" }, "CloudWatchConfig": { "RoleArn": "string" }, "RDSSourceConfig": { "DatabaseHost": "string", "DatabaseName": "string", "DatabasePort": number, "DBInstanceIdentifier": "string", "RoleArn": "string", "SecretManagerArn": "string", "TableName": "string", "VpcConfiguration": { "SecurityGroupIdList": [ "string" ], "SubnetIdList": [ "string" ] } }, "RedshiftSourceConfig": { "ClusterIdentifier": "string", "DatabaseHost": "string", "DatabaseName": "string", "DatabasePort": number, "RoleArn": "string", "SecretManagerArn": "string", "TableName": "string", "VpcConfiguration": { "SecurityGroupIdList": [ "string" ], "SubnetIdList": [ "string" ] } }, "S3SourceConfig": { "FileFormatDescriptor": { "CsvFormatDescriptor": { "Charset": "string", "ContainsHeader": boolean, "Delimiter": "string", "FileCompression": "string", "HeaderList": [ "string" ], "QuoteSymbol": "string" }, "JsonFormatDescriptor": { "Charset": "string", "FileCompression": "string" } }, "HistoricalDataPathList": [ "string" ], "RoleArn": "string", "TemplatedPathList": [ "string" ] } }, "Offset": number, "TimestampColumn": { "ColumnFormat": "string", "ColumnName": "string" } }

URI Request Parameters

The request does not use any URI parameters.

Request Body

The request accepts the following data in JSON format.

DimensionList

The dimension list.

Type: Array of strings

Array Members: Minimum number of 1 item.

Length Constraints: Minimum length of 1. Maximum length of 63.

Pattern: ^[a-zA-Z0-9][a-zA-Z0-9\-_]*

Required: No

MetricList

The metric list.

Type: Array of Metric objects

Array Members: Minimum number of 1 item.

Required: No

MetricSetArn

The ARN of the dataset to update.

Type: String

Length Constraints: Maximum length of 256.

Pattern: arn:([a-z\d-]+):.*:.*:.*:.+

Required: Yes

MetricSetDescription

The dataset's description.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 256.

Pattern: .*\S.*

Required: No

MetricSetFrequency

The dataset's interval.

Type: String

Valid Values: P1D | PT1H | PT10M | PT5M

Required: No

MetricSource

Contains information about source data used to generate a metric.

Type: MetricSource object

Required: No

Offset

After an interval ends, the amount of seconds that the detector waits before importing data. Offset is only supported for S3 and Redshift datasources.

Type: Integer

Valid Range: Minimum value of 0. Maximum value of 432000.

Required: No

TimestampColumn

The timestamp column.

Type: TimestampColumn object

Required: No

Response Syntax

HTTP/1.1 200 Content-type: application/json { "MetricSetArn": "string" }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

MetricSetArn

The ARN of the dataset.

Type: String

Length Constraints: Maximum length of 256.

Pattern: arn:([a-z\d-]+):.*:.*:.*:.+

Errors

For information about the errors that are common to all actions, see Common Errors.

AccessDeniedException

You do not have sufficient permissions to perform this action.

HTTP Status Code: 403

InternalServerException

The request processing has failed because of an unknown error, exception, or failure.

HTTP Status Code: 500

ResourceNotFoundException

The specified resource cannot be found. Check the ARN of the resource and try again.

HTTP Status Code: 400

TooManyRequestsException

The request was denied due to too many requests being submitted at the same time.

HTTP Status Code: 429

ValidationException

The input fails to satisfy the constraints specified by the AWS service. Check your input values and try again.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: