Class: AWS.ApplicationSignals
- Inherits:
-
AWS.Service
- Object
- AWS.Service
- AWS.ApplicationSignals
- Identifier:
- applicationsignals
- API Version:
- 2024-04-15
- Defined in:
- (unknown)
Overview
Constructs a service interface object. Each API operation is exposed as a function on service.
Service Description
Use CloudWatch Application Signals for comprehensive observability of your cloud-based applications. It enables real-time service health dashboards and helps you track long-term performance trends against your business goals. The application-centric view provides you with unified visibility across your applications, services, and dependencies, so you can proactively monitor and efficiently triage any issues that may arise, ensuring optimal customer experience.
Application Signals provides the following benefits:
-
Automatically collect metrics and traces from your applications, and display key metrics such as call volume, availability, latency, faults, and errors.
-
Create and monitor service level objectives (SLOs).
-
See a map of your application topology that Application Signals automatically discovers, that gives you a visual representation of your applications, dependencies, and their connectivity.
Application Signals works with CloudWatch RUM, CloudWatch Synthetics canaries, and Amazon Web Services Service Catalog AppRegistry, to display your client pages, Synthetics canaries, and application names within dashboards and maps.
Sending a Request Using ApplicationSignals
var applicationsignals = new AWS.ApplicationSignals();
applicationsignals.batchGetServiceLevelObjectiveBudgetReport(params, function (err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Locking the API Version
In order to ensure that the ApplicationSignals object uses this specific API, you can
construct the object by passing the apiVersion
option to the constructor:
var applicationsignals = new AWS.ApplicationSignals({apiVersion: '2024-04-15'});
You can also set the API version globally in AWS.config.apiVersions
using
the applicationsignals service identifier:
AWS.config.apiVersions = {
applicationsignals: '2024-04-15',
// other service API versions
};
var applicationsignals = new AWS.ApplicationSignals();
Version:
-
2024-04-15
Constructor Summary collapse
-
new AWS.ApplicationSignals(options = {}) ⇒ Object
constructor
Constructs a service object.
Property Summary collapse
-
endpoint ⇒ AWS.Endpoint
readwrite
An Endpoint object representing the endpoint URL for service requests.
Properties inherited from AWS.Service
Method Summary collapse
-
batchGetServiceLevelObjectiveBudgetReport(params = {}, callback) ⇒ AWS.Request
Use this operation to retrieve one or more service level objective (SLO) budget reports.
An error budget is the amount of time or requests in an unhealthy state that your service can accumulate during an interval before your overall SLO budget health is breached and the SLO is considered to be unmet.
-
createServiceLevelObjective(params = {}, callback) ⇒ AWS.Request
Creates a service level objective (SLO), which can help you ensure that your critical business operations are meeting customer expectations.
-
deleteServiceLevelObjective(params = {}, callback) ⇒ AWS.Request
Deletes the specified service level objective.
.
-
getService(params = {}, callback) ⇒ AWS.Request
Returns information about a service discovered by Application Signals.
.
-
getServiceLevelObjective(params = {}, callback) ⇒ AWS.Request
Returns information about one SLO created in the account.
-
listServiceDependencies(params = {}, callback) ⇒ AWS.Request
Returns a list of service dependencies of the service that you specify.
-
listServiceDependents(params = {}, callback) ⇒ AWS.Request
Returns the list of dependents that invoked the specified service during the provided time range.
-
listServiceLevelObjectives(params = {}, callback) ⇒ AWS.Request
Returns a list of SLOs created in this account.
.
-
listServiceOperations(params = {}, callback) ⇒ AWS.Request
Returns a list of the operations of this service that have been discovered by Application Signals.
-
listServices(params = {}, callback) ⇒ AWS.Request
Returns a list of services that have been discovered by Application Signals.
-
listTagsForResource(params = {}, callback) ⇒ AWS.Request
Displays the tags associated with a CloudWatch resource.
-
startDiscovery(params = {}, callback) ⇒ AWS.Request
Enables this Amazon Web Services account to be able to use CloudWatch Application Signals by creating the AWSServiceRoleForCloudWatchApplicationSignals service-linked role.
-
tagResource(params = {}, callback) ⇒ AWS.Request
Assigns one or more tags (key-value pairs) to the specified CloudWatch resource, such as a service level objective.
Tags can help you organize and categorize your resources.
-
untagResource(params = {}, callback) ⇒ AWS.Request
Removes one or more tags from the specified resource.
.
-
updateServiceLevelObjective(params = {}, callback) ⇒ AWS.Request
Updates an existing service level objective (SLO).
Methods inherited from AWS.Service
makeRequest, makeUnauthenticatedRequest, waitFor, setupRequestListeners, defineService
Constructor Details
new AWS.ApplicationSignals(options = {}) ⇒ Object
Constructs a service object. This object has one method for each API operation.
Examples:
Constructing a ApplicationSignals object
var applicationsignals = new AWS.ApplicationSignals({apiVersion: '2024-04-15'});
Options Hash (options):
-
params
(map)
—
An optional map of parameters to bind to every request sent by this service object. For more information on bound parameters, see "Working with Services" in the Getting Started Guide.
-
endpoint
(String|AWS.Endpoint)
—
The endpoint URI to send requests to. The default endpoint is built from the configured
region
. The endpoint should be a string like'https://{service}.{region}.amazonaws.com'
or an Endpoint object. -
accessKeyId
(String)
—
your AWS access key ID.
-
secretAccessKey
(String)
—
your AWS secret access key.
-
sessionToken
(AWS.Credentials)
—
the optional AWS session token to sign requests with.
-
credentials
(AWS.Credentials)
—
the AWS credentials to sign requests with. You can either specify this object, or specify the accessKeyId and secretAccessKey options directly.
-
credentialProvider
(AWS.CredentialProviderChain)
—
the provider chain used to resolve credentials if no static
credentials
property is set. -
region
(String)
—
the region to send service requests to. See AWS.ApplicationSignals.region for more information.
-
maxRetries
(Integer)
—
the maximum amount of retries to attempt with a request. See AWS.ApplicationSignals.maxRetries for more information.
-
maxRedirects
(Integer)
—
the maximum amount of redirects to follow with a request. See AWS.ApplicationSignals.maxRedirects for more information.
-
sslEnabled
(Boolean)
—
whether to enable SSL for requests.
-
paramValidation
(Boolean|map)
—
whether input parameters should be validated against the operation description before sending the request. Defaults to true. Pass a map to enable any of the following specific validation features:
- min [Boolean] — Validates that a value meets the min
constraint. This is enabled by default when paramValidation is set
to
true
. - max [Boolean] — Validates that a value meets the max constraint.
- pattern [Boolean] — Validates that a string value matches a regular expression.
- enum [Boolean] — Validates that a string value matches one of the allowable enum values.
- min [Boolean] — Validates that a value meets the min
constraint. This is enabled by default when paramValidation is set
to
-
computeChecksums
(Boolean)
—
whether to compute checksums for payload bodies when the service accepts it (currently supported in S3 only)
-
convertResponseTypes
(Boolean)
—
whether types are converted when parsing response data. Currently only supported for JSON based services. Turning this off may improve performance on large response payloads. Defaults to
true
. -
correctClockSkew
(Boolean)
—
whether to apply a clock skew correction and retry requests that fail because of an skewed client clock. Defaults to
false
. -
s3ForcePathStyle
(Boolean)
—
whether to force path style URLs for S3 objects.
-
s3BucketEndpoint
(Boolean)
—
whether the provided endpoint addresses an individual bucket (false if it addresses the root API endpoint). Note that setting this configuration option requires an
endpoint
to be provided explicitly to the service constructor. -
s3DisableBodySigning
(Boolean)
—
whether S3 body signing should be disabled when using signature version
v4
. Body signing can only be disabled when using https. Defaults totrue
. -
s3UsEast1RegionalEndpoint
('legacy'|'regional')
—
when region is set to 'us-east-1', whether to send s3 request to global endpoints or 'us-east-1' regional endpoints. This config is only applicable to S3 client. Defaults to
legacy
-
s3UseArnRegion
(Boolean)
—
whether to override the request region with the region inferred from requested resource's ARN. Only available for S3 buckets Defaults to
true
-
retryDelayOptions
(map)
—
A set of options to configure the retry delay on retryable errors. Currently supported options are:
- base [Integer] — The base number of milliseconds to use in the exponential backoff for operation retries. Defaults to 100 ms for all services except DynamoDB, where it defaults to 50ms.
- customBackoff [function] — A custom function that accepts a
retry count and error and returns the amount of time to delay in
milliseconds. If the result is a non-zero negative value, no further
retry attempts will be made. The
base
option will be ignored if this option is supplied. The function is only called for retryable errors.
-
httpOptions
(map)
—
A set of options to pass to the low-level HTTP request. Currently supported options are:
- proxy [String] — the URL to proxy requests through
- agent [http.Agent, https.Agent] — the Agent object to perform
HTTP requests with. Used for connection pooling. Defaults to the global
agent (
http.globalAgent
) for non-SSL connections. Note that for SSL connections, a special Agent object is used in order to enable peer certificate verification. This feature is only available in the Node.js environment. - connectTimeout [Integer] — Sets the socket to timeout after
failing to establish a connection with the server after
connectTimeout
milliseconds. This timeout has no effect once a socket connection has been established. - timeout [Integer] — Sets the socket to timeout after timeout milliseconds of inactivity on the socket. Defaults to two minutes (120000).
- xhrAsync [Boolean] — Whether the SDK will send asynchronous HTTP requests. Used in the browser environment only. Set to false to send requests synchronously. Defaults to true (async on).
- xhrWithCredentials [Boolean] — Sets the "withCredentials" property of an XMLHttpRequest object. Used in the browser environment only. Defaults to false.
-
apiVersion
(String, Date)
—
a String in YYYY-MM-DD format (or a date) that represents the latest possible API version that can be used in all services (unless overridden by
apiVersions
). Specify 'latest' to use the latest possible version. -
apiVersions
(map<String, String|Date>)
—
a map of service identifiers (the lowercase service class name) with the API version to use when instantiating a service. Specify 'latest' for each individual that can use the latest available version.
-
logger
(#write, #log)
—
an object that responds to .write() (like a stream) or .log() (like the console object) in order to log information about requests
-
systemClockOffset
(Number)
—
an offset value in milliseconds to apply to all signing times. Use this to compensate for clock skew when your system may be out of sync with the service time. Note that this configuration option can only be applied to the global
AWS.config
object and cannot be overridden in service-specific configuration. Defaults to 0 milliseconds. -
signatureVersion
(String)
—
the signature version to sign requests with (overriding the API configuration). Possible values are: 'v2', 'v3', 'v4'.
-
signatureCache
(Boolean)
—
whether the signature to sign requests with (overriding the API configuration) is cached. Only applies to the signature version 'v4'. Defaults to
true
. -
dynamoDbCrc32
(Boolean)
—
whether to validate the CRC32 checksum of HTTP response bodies returned by DynamoDB. Default:
true
. -
useAccelerateEndpoint
(Boolean)
—
Whether to use the S3 Transfer Acceleration endpoint with the S3 service. Default:
false
. -
clientSideMonitoring
(Boolean)
—
whether to collect and publish this client's performance metrics of all its API requests.
-
endpointDiscoveryEnabled
(Boolean|undefined)
—
whether to call operations with endpoints given by service dynamically. Setting this
-
endpointCacheSize
(Number)
—
the size of the global cache storing endpoints from endpoint discovery operations. Once endpoint cache is created, updating this setting cannot change existing cache size. Defaults to 1000
-
hostPrefixEnabled
(Boolean)
—
whether to marshal request parameters to the prefix of hostname. Defaults to
true
. -
stsRegionalEndpoints
('legacy'|'regional')
—
whether to send sts request to global endpoints or regional endpoints. Defaults to 'legacy'.
-
useFipsEndpoint
(Boolean)
—
Enables FIPS compatible endpoints. Defaults to
false
. -
useDualstackEndpoint
(Boolean)
—
Enables IPv6 dualstack endpoint. Defaults to
false
.
Property Details
Method Details
batchGetServiceLevelObjectiveBudgetReport(params = {}, callback) ⇒ AWS.Request
Use this operation to retrieve one or more service level objective (SLO) budget reports.
An error budget is the amount of time or requests in an unhealthy state that your service can accumulate during an interval before your overall SLO budget health is breached and the SLO is considered to be unmet. For example, an SLO with a threshold of 99.95% and a monthly interval translates to an error budget of 21.9 minutes of downtime in a 30-day month.
Budget reports include a health indicator, the attainment value, and remaining budget.
For more information about SLO error budgets, see SLO concepts.
Service Reference:
Examples:
Calling the batchGetServiceLevelObjectiveBudgetReport operation
var params = {
SloIds: [ /* required */
'STRING_VALUE',
/* more items */
],
Timestamp: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789 /* required */
};
applicationsignals.batchGetServiceLevelObjectiveBudgetReport(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
Timestamp
— (Date
)The date and time that you want the report to be for. It is expressed as the number of milliseconds since Jan 1, 1970 00:00:00 UTC.
SloIds
— (Array<String>
)An array containing the IDs of the service level objectives that you want to include in the report.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:Timestamp
— (Date
)The date and time that the report is for. It is expressed as the number of milliseconds since Jan 1, 1970 00:00:00 UTC.
Reports
— (Array<map>
)An array of structures, where each structure is one budget report.
Arn
— required — (String
)The ARN of the SLO that this report is for.
Name
— required — (String
)The name of the SLO that this report is for.
EvaluationType
— (String
)Displays whether this budget report is for a period-based SLO or a request-based SLO.
Possible values include:"PeriodBased"
"RequestBased"
BudgetStatus
— required — (String
)The status of this SLO, as it relates to the error budget for the entire time interval.
-
OK
means that the SLO had remaining budget above the warning threshold, as of the time that you specified inTimeStamp
. -
WARNING
means that the SLO's remaining budget was below the warning threshold, as of the time that you specified inTimeStamp
. -
BREACHED
means that the SLO's budget was exhausted, as of the time that you specified inTimeStamp
. -
INSUFFICIENT_DATA
means that the specified start and end times were before the SLO was created, or that attainment data is missing.
"OK"
"WARNING"
"BREACHED"
"INSUFFICIENT_DATA"
-
Attainment
— (Float
)A number between 0 and 100 that represents the success percentage of your application compared to the goal set by the SLO.
If this is a period-based SLO, the number is the percentage of time periods that the service has attained the SLO's attainment goal, as of the time of the request.
If this is a request-based SLO, the number is the number of successful requests divided by the number of total requests, multiplied by 100, during the time range that you specified in your request.
TotalBudgetSeconds
— (Integer
)The total number of seconds in the error budget for the interval. This field is included only if the SLO is a period-based SLO.
BudgetSecondsRemaining
— (Integer
)The budget amount remaining before the SLO status becomes
BREACHING
, at the time specified in theTimestemp
parameter of the request. If this value is negative, then the SLO is already inBREACHING
status.This field is included only if the SLO is a period-based SLO.
TotalBudgetRequests
— (Integer
)This field is displayed only for request-based SLOs. It displays the total number of failed requests that can be tolerated during the time range between the start of the interval and the time stamp supplied in the budget report request. It is based on the total number of requests that occurred, and the percentage specified in the attainment goal. If the number of failed requests matches this number or is higher, then this SLO is currently breaching.
This number can go up and down between reports with different time stamps, based on both how many total requests occur.
BudgetRequestsRemaining
— (Integer
)This field is displayed only for request-based SLOs. It displays the number of failed requests that can be tolerated before any more successful requests occur, and still have the application meet its SLO goal.
This number can go up and down between different reports, based on both how many successful requests and how many failed requests occur in that time.
Sli
— (map
)A structure that contains information about the performance metric that this SLO monitors.
SliMetric
— required — (map
)A structure that contains information about the metric that the SLO monitors.
KeyAttributes
— (map<String>
)This is a string-to-string map that contains information about the type of object that this SLO is related to. It can include the following fields.
-
Type
designates the type of object that this SLO is related to. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO monitors a specific operation of the service, this field displays that operation name.
MetricType
— (String
)If the SLO monitors either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, this field displays which of those metrics is used."LATENCY"
"AVAILABILITY"
MetricDataQueries
— required — (Array<map>
)If this SLO monitors a CloudWatch metric or the result of a CloudWatch metric math expression, this structure includes the information about that metric or expression.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— required — (Float
)The value that the SLI metric is compared to.
ComparisonOperator
— required — (String
)The arithmetic operation used when comparing the specified metric to the threshold.
Possible values include:"GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
RequestBasedSli
— (map
)This structure contains information about the performance metric that a request-based SLO monitors.
RequestBasedSliMetric
— required — (map
)A structure that contains information about the metric that the SLO monitors.
KeyAttributes
— (map<String>
)This is a string-to-string map that contains information about the type of object that this SLO is related to. It can include the following fields.
-
Type
designates the type of object that this SLO is related to. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO monitors a specific operation of the service, this field displays that operation name.
MetricType
— (String
)If the SLO monitors either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, this field displays which of those metrics is used."LATENCY"
"AVAILABILITY"
TotalRequestCountMetric
— required — (Array<map>
)This structure defines the metric that is used as the "total requests" number for a request-based SLO. The number observed for this metric is divided by the number of "good requests" or "bad requests" that is observed for the metric defined in
MonitoredRequestCountMetric
.Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MonitoredRequestCountMetric
— required — (map
)This structure defines the metric that is used as the "good request" or "bad request" value for a request-based SLO. This value observed for the metric defined in
TotalRequestCountMetric
is divided by the number found forMonitoredRequestCountMetric
to determine the percentage of successful requests that this SLO tracks.GoodCountMetric
— (Array<map>
)If you want to count "good requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "good requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
BadCountMetric
— (Array<map>
)If you want to count "bad requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "bad requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— (Float
)This value is the threshold that the observed metric values of the SLI metric are compared to.
ComparisonOperator
— (String
)The arithmetic operation used when comparing the specified metric to the threshold.
Possible values include:"GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
Goal
— (map
)This structure contains the attributes that determine the goal of an SLO. This includes the time period for evaluation and the attainment threshold.
Interval
— (map
)The time period used to evaluate the SLO. It can be either a calendar interval or rolling interval.
If you omit this parameter, a rolling interval of 7 days is used.
RollingInterval
— (map
)If the interval is a rolling interval, this structure contains the interval specifications.
DurationUnit
— required — (String
)Specifies the rolling interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each rolling interval. For example, if
Duration
is7
andDurationUnit
isDAY
, each rolling interval is seven days.
CalendarInterval
— (map
)If the interval is a calendar interval, this structure contains the interval specifications.
StartTime
— required — (Date
)The date and time when you want the first interval to start. Be sure to choose a time that configures the intervals the way that you want. For example, if you want weekly intervals starting on Mondays at 6 a.m., be sure to specify a start time that is a Monday at 6 a.m.
When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
As soon as one calendar interval ends, another automatically begins.
DurationUnit
— required — (String
)Specifies the calendar interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each calendar interval. For example, if
Duration
is1
andDurationUnit
isMONTH
, each interval is one month, aligned with the calendar.
AttainmentGoal
— (Float
)The threshold that determines if the goal is being met.
If this is a period-based SLO, the attainment goal is the percentage of good periods that meet the threshold requirements to the total periods within the interval. For example, an attainment goal of 99.9% means that within your interval, you are targeting 99.9% of the periods to be in healthy state.
If this is a request-based SLO, the attainment goal is the percentage of requests that must be successful to meet the attainment goal.
If you omit this parameter, 99 is used to represent 99% as the attainment goal.
WarningThreshold
— (Float
)The percentage of remaining budget over total budget that you want to get warnings for. If you omit this parameter, the default of 50.0 is used.
Errors
— (Array<map>
)An array of structures, where each structure includes an error indicating that one of the requests in the array was not valid.
Name
— required — (String
)The name of the SLO that this error is related to.
Arn
— required — (String
)The ARN of the SLO that this error is related to.
ErrorCode
— required — (String
)The error code for this error.
ErrorMessage
— required — (String
)The message for this error.
-
(AWS.Response)
—
Returns:
createServiceLevelObjective(params = {}, callback) ⇒ AWS.Request
Creates a service level objective (SLO), which can help you ensure that your critical business operations are meeting customer expectations. Use SLOs to set and track specific target levels for the reliability and availability of your applications and services. SLOs use service level indicators (SLIs) to calculate whether the application is performing at the level that you want.
Create an SLO to set a target for a service or operation’s availability or latency. CloudWatch measures this target frequently you can find whether it has been breached.
The target performance quality that is defined for an SLO is the attainment goal.
You can set SLO targets for your applications that are discovered by Application Signals, using critical metrics such as latency and availability. You can also set SLOs against any CloudWatch metric or math expression that produces a time series.
When you create an SLO, you specify whether it is a period-based SLO or a request-based SLO. Each type of SLO has a different way of evaluating your application's performance against its attainment goal.
-
A period-based SLO uses defined periods of time within a specified total time interval. For each period of time, Application Signals determines whether the application met its goal. The attainment rate is calculated as the
number of good periods/number of total periods
.For example, for a period-based SLO, meeting an attainment goal of 99.9% means that within your interval, your application must meet its performance goal during at least 99.9% of the time periods.
-
A request-based SLO doesn't use pre-defined periods of time. Instead, the SLO measures
number of good requests/number of total requests
during the interval. At any time, you can find the ratio of good requests to total requests for the interval up to the time stamp that you specify, and measure that ratio against the goal set in your SLO.
After you have created an SLO, you can retrieve error budget reports for it. An error budget is the amount of time or amount of requests that your application can be non-compliant with the SLO's goal, and still have your application meet the goal.
-
For a period-based SLO, the error budget starts at a number defined by the highest number of periods that can fail to meet the threshold, while still meeting the overall goal. The remaining error budget decreases with every failed period that is recorded. The error budget within one interval can never increase.
For example, an SLO with a threshold that 99.95% of requests must be completed under 2000ms every month translates to an error budget of 21.9 minutes of downtime per month.
-
For a request-based SLO, the remaining error budget is dynamic and can increase or decrease, depending on the ratio of good requests to total requests.
For more information about SLOs, see Service level objectives (SLOs).
When you perform a CreateServiceLevelObjective
operation, Application Signals creates the AWSServiceRoleForCloudWatchApplicationSignals service-linked role, if it doesn't already exist in your account. This service- linked role has the following permissions:
-
xray:GetServiceGraph
-
logs:StartQuery
-
logs:GetQueryResults
-
cloudwatch:GetMetricData
-
cloudwatch:ListMetrics
-
tag:GetResources
-
autoscaling:DescribeAutoScalingGroups
Service Reference:
Examples:
Calling the createServiceLevelObjective operation
var params = {
Name: 'STRING_VALUE', /* required */
Description: 'STRING_VALUE',
Goal: {
AttainmentGoal: 'NUMBER_VALUE',
Interval: {
CalendarInterval: {
Duration: 'NUMBER_VALUE', /* required */
DurationUnit: MINUTE | HOUR | DAY | MONTH, /* required */
StartTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789 /* required */
},
RollingInterval: {
Duration: 'NUMBER_VALUE', /* required */
DurationUnit: MINUTE | HOUR | DAY | MONTH /* required */
}
},
WarningThreshold: 'NUMBER_VALUE'
},
RequestBasedSliConfig: {
RequestBasedSliMetricConfig: { /* required */
KeyAttributes: {
'<KeyAttributeName>': 'STRING_VALUE',
/* '<KeyAttributeName>': ... */
},
MetricType: LATENCY | AVAILABILITY,
MonitoredRequestCountMetric: {
BadCountMetric: [
{
Id: 'STRING_VALUE', /* required */
AccountId: 'STRING_VALUE',
Expression: 'STRING_VALUE',
Label: 'STRING_VALUE',
MetricStat: {
Metric: { /* required */
Dimensions: [
{
Name: 'STRING_VALUE', /* required */
Value: 'STRING_VALUE' /* required */
},
/* more items */
],
MetricName: 'STRING_VALUE',
Namespace: 'STRING_VALUE'
},
Period: 'NUMBER_VALUE', /* required */
Stat: 'STRING_VALUE', /* required */
Unit: Microseconds | Milliseconds | Seconds | Bytes | Kilobytes | Megabytes | Gigabytes | Terabytes | Bits | Kilobits | Megabits | Gigabits | Terabits | Percent | Count | Bytes/Second | Kilobytes/Second | Megabytes/Second | Gigabytes/Second | Terabytes/Second | Bits/Second | Kilobits/Second | Megabits/Second | Gigabits/Second | Terabits/Second | Count/Second | None
},
Period: 'NUMBER_VALUE',
ReturnData: true || false
},
/* more items */
],
GoodCountMetric: [
{
Id: 'STRING_VALUE', /* required */
AccountId: 'STRING_VALUE',
Expression: 'STRING_VALUE',
Label: 'STRING_VALUE',
MetricStat: {
Metric: { /* required */
Dimensions: [
{
Name: 'STRING_VALUE', /* required */
Value: 'STRING_VALUE' /* required */
},
/* more items */
],
MetricName: 'STRING_VALUE',
Namespace: 'STRING_VALUE'
},
Period: 'NUMBER_VALUE', /* required */
Stat: 'STRING_VALUE', /* required */
Unit: Microseconds | Milliseconds | Seconds | Bytes | Kilobytes | Megabytes | Gigabytes | Terabytes | Bits | Kilobits | Megabits | Gigabits | Terabits | Percent | Count | Bytes/Second | Kilobytes/Second | Megabytes/Second | Gigabytes/Second | Terabytes/Second | Bits/Second | Kilobits/Second | Megabits/Second | Gigabits/Second | Terabits/Second | Count/Second | None
},
Period: 'NUMBER_VALUE',
ReturnData: true || false
},
/* more items */
]
},
OperationName: 'STRING_VALUE',
TotalRequestCountMetric: [
{
Id: 'STRING_VALUE', /* required */
AccountId: 'STRING_VALUE',
Expression: 'STRING_VALUE',
Label: 'STRING_VALUE',
MetricStat: {
Metric: { /* required */
Dimensions: [
{
Name: 'STRING_VALUE', /* required */
Value: 'STRING_VALUE' /* required */
},
/* more items */
],
MetricName: 'STRING_VALUE',
Namespace: 'STRING_VALUE'
},
Period: 'NUMBER_VALUE', /* required */
Stat: 'STRING_VALUE', /* required */
Unit: Microseconds | Milliseconds | Seconds | Bytes | Kilobytes | Megabytes | Gigabytes | Terabytes | Bits | Kilobits | Megabits | Gigabits | Terabits | Percent | Count | Bytes/Second | Kilobytes/Second | Megabytes/Second | Gigabytes/Second | Terabytes/Second | Bits/Second | Kilobits/Second | Megabits/Second | Gigabits/Second | Terabits/Second | Count/Second | None
},
Period: 'NUMBER_VALUE',
ReturnData: true || false
},
/* more items */
]
},
ComparisonOperator: GreaterThanOrEqualTo | GreaterThan | LessThan | LessThanOrEqualTo,
MetricThreshold: 'NUMBER_VALUE'
},
SliConfig: {
ComparisonOperator: GreaterThanOrEqualTo | GreaterThan | LessThan | LessThanOrEqualTo, /* required */
MetricThreshold: 'NUMBER_VALUE', /* required */
SliMetricConfig: { /* required */
KeyAttributes: {
'<KeyAttributeName>': 'STRING_VALUE',
/* '<KeyAttributeName>': ... */
},
MetricDataQueries: [
{
Id: 'STRING_VALUE', /* required */
AccountId: 'STRING_VALUE',
Expression: 'STRING_VALUE',
Label: 'STRING_VALUE',
MetricStat: {
Metric: { /* required */
Dimensions: [
{
Name: 'STRING_VALUE', /* required */
Value: 'STRING_VALUE' /* required */
},
/* more items */
],
MetricName: 'STRING_VALUE',
Namespace: 'STRING_VALUE'
},
Period: 'NUMBER_VALUE', /* required */
Stat: 'STRING_VALUE', /* required */
Unit: Microseconds | Milliseconds | Seconds | Bytes | Kilobytes | Megabytes | Gigabytes | Terabytes | Bits | Kilobits | Megabits | Gigabits | Terabits | Percent | Count | Bytes/Second | Kilobytes/Second | Megabytes/Second | Gigabytes/Second | Terabytes/Second | Bits/Second | Kilobits/Second | Megabits/Second | Gigabits/Second | Terabits/Second | Count/Second | None
},
Period: 'NUMBER_VALUE',
ReturnData: true || false
},
/* more items */
],
MetricType: LATENCY | AVAILABILITY,
OperationName: 'STRING_VALUE',
PeriodSeconds: 'NUMBER_VALUE',
Statistic: 'STRING_VALUE'
}
},
Tags: [
{
Key: 'STRING_VALUE', /* required */
Value: 'STRING_VALUE' /* required */
},
/* more items */
]
};
applicationsignals.createServiceLevelObjective(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
Name
— (String
)A name for this SLO.
Description
— (String
)An optional description for this SLO.
SliConfig
— (map
)If this SLO is a period-based SLO, this structure defines the information about what performance metric this SLO will monitor.
You can't specify both
RequestBasedSliConfig
andSliConfig
in the same operation.SliMetricConfig
— required — (map
)Use this structure to specify the metric to be used for the SLO.
KeyAttributes
— (map<String>
)If this SLO is related to a metric collected by Application Signals, you must use this field to specify which service the SLO metric is related to. To do so, you must specify at least the
Type
,Name
, andEnvironment
attributes.This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO is to monitor a specific operation of the service, use this field to specify the name of that operation.
MetricType
— (String
)If the SLO is to monitor either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, use this field to specify which of those metrics is used."LATENCY"
"AVAILABILITY"
Statistic
— (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
PeriodSeconds
— (Integer
)The number of seconds to use as the period for SLO evaluation. Your application's performance is compared to the SLI during each period. For each period, the application is determined to have either achieved or not achieved the necessary performance.
MetricDataQueries
— (Array<map>
)If this SLO monitors a CloudWatch metric or the result of a CloudWatch metric math expression, use this structure to specify that metric or expression.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— required — (Float
)This parameter is used only when a request-based SLO tracks the
Latency
metric. Specify the threshold value that the observedLatency
metric values are to be compared to.ComparisonOperator
— required — (String
)The arithmetic operation to use when comparing the specified metric to the threshold.
Possible values include:"GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
RequestBasedSliConfig
— (map
)If this SLO is a request-based SLO, this structure defines the information about what performance metric this SLO will monitor.
You can't specify both
RequestBasedSliConfig
andSliConfig
in the same operation.RequestBasedSliMetricConfig
— required — (map
)Use this structure to specify the metric to be used for the SLO.
KeyAttributes
— (map<String>
)If this SLO is related to a metric collected by Application Signals, you must use this field to specify which service the SLO metric is related to. To do so, you must specify at least the
Type
,Name
, andEnvironment
attributes.This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO is to monitor a specific operation of the service, use this field to specify the name of that operation.
MetricType
— (String
)If the SLO is to monitor either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, use this field to specify which of those metrics is used."LATENCY"
"AVAILABILITY"
TotalRequestCountMetric
— (Array<map>
)Use this structure to define the metric that you want to use as the "total requests" number for a request-based SLO. This result will be divided by the "good request" or "bad request" value defined in
MonitoredRequestCountMetric
.Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MonitoredRequestCountMetric
— (map
)Use this structure to define the metric that you want to use as the "good request" or "bad request" value for a request-based SLO. This value observed for the metric defined in
TotalRequestCountMetric
will be divided by the number found forMonitoredRequestCountMetric
to determine the percentage of successful requests that this SLO tracks.GoodCountMetric
— (Array<map>
)If you want to count "good requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "good requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
BadCountMetric
— (Array<map>
)If you want to count "bad requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "bad requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— (Float
)The value that the SLI metric is compared to. This parameter is required if this SLO is tracking the
Latency
metric.ComparisonOperator
— (String
)The arithmetic operation to use when comparing the specified metric to the threshold. This parameter is required if this SLO is tracking the
Possible values include:Latency
metric."GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
Goal
— (map
)This structure contains the attributes that determine the goal of the SLO.
Interval
— (map
)The time period used to evaluate the SLO. It can be either a calendar interval or rolling interval.
If you omit this parameter, a rolling interval of 7 days is used.
RollingInterval
— (map
)If the interval is a rolling interval, this structure contains the interval specifications.
DurationUnit
— required — (String
)Specifies the rolling interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each rolling interval. For example, if
Duration
is7
andDurationUnit
isDAY
, each rolling interval is seven days.
CalendarInterval
— (map
)If the interval is a calendar interval, this structure contains the interval specifications.
StartTime
— required — (Date
)The date and time when you want the first interval to start. Be sure to choose a time that configures the intervals the way that you want. For example, if you want weekly intervals starting on Mondays at 6 a.m., be sure to specify a start time that is a Monday at 6 a.m.
When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
As soon as one calendar interval ends, another automatically begins.
DurationUnit
— required — (String
)Specifies the calendar interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each calendar interval. For example, if
Duration
is1
andDurationUnit
isMONTH
, each interval is one month, aligned with the calendar.
AttainmentGoal
— (Float
)The threshold that determines if the goal is being met.
If this is a period-based SLO, the attainment goal is the percentage of good periods that meet the threshold requirements to the total periods within the interval. For example, an attainment goal of 99.9% means that within your interval, you are targeting 99.9% of the periods to be in healthy state.
If this is a request-based SLO, the attainment goal is the percentage of requests that must be successful to meet the attainment goal.
If you omit this parameter, 99 is used to represent 99% as the attainment goal.
WarningThreshold
— (Float
)The percentage of remaining budget over total budget that you want to get warnings for. If you omit this parameter, the default of 50.0 is used.
Tags
— (Array<map>
)A list of key-value pairs to associate with the SLO. You can associate as many as 50 tags with an SLO. To be able to associate tags with the SLO when you create the SLO, you must have the
cloudwatch:TagResource
permission.Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only resources with certain tag values.
Key
— required — (String
)A string that you can use to assign a value. The combination of tag keys and values can help you organize and categorize your resources.
Value
— required — (String
)The value for the specified tag key.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:Slo
— (map
)A structure that contains information about the SLO that you just created.
Arn
— required — (String
)The ARN of this SLO.
Name
— required — (String
)The name of this SLO.
Description
— (String
)The description that you created for this SLO.
CreatedTime
— required — (Date
)The date and time that this SLO was created. When used in a raw HTTP Query API, it is formatted as
yyyy-MM-dd'T'HH:mm:ss
. For example,2019-07-01T23:59:59
.LastUpdatedTime
— required — (Date
)The time that this SLO was most recently updated. When used in a raw HTTP Query API, it is formatted as
yyyy-MM-dd'T'HH:mm:ss
. For example,2019-07-01T23:59:59
.Sli
— (map
)A structure containing information about the performance metric that this SLO monitors, if this is a period-based SLO.
SliMetric
— required — (map
)A structure that contains information about the metric that the SLO monitors.
KeyAttributes
— (map<String>
)This is a string-to-string map that contains information about the type of object that this SLO is related to. It can include the following fields.
-
Type
designates the type of object that this SLO is related to. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO monitors a specific operation of the service, this field displays that operation name.
MetricType
— (String
)If the SLO monitors either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, this field displays which of those metrics is used."LATENCY"
"AVAILABILITY"
MetricDataQueries
— required — (Array<map>
)If this SLO monitors a CloudWatch metric or the result of a CloudWatch metric math expression, this structure includes the information about that metric or expression.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— required — (Float
)The value that the SLI metric is compared to.
ComparisonOperator
— required — (String
)The arithmetic operation used when comparing the specified metric to the threshold.
Possible values include:"GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
RequestBasedSli
— (map
)A structure containing information about the performance metric that this SLO monitors, if this is a request-based SLO.
RequestBasedSliMetric
— required — (map
)A structure that contains information about the metric that the SLO monitors.
KeyAttributes
— (map<String>
)This is a string-to-string map that contains information about the type of object that this SLO is related to. It can include the following fields.
-
Type
designates the type of object that this SLO is related to. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO monitors a specific operation of the service, this field displays that operation name.
MetricType
— (String
)If the SLO monitors either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, this field displays which of those metrics is used."LATENCY"
"AVAILABILITY"
TotalRequestCountMetric
— required — (Array<map>
)This structure defines the metric that is used as the "total requests" number for a request-based SLO. The number observed for this metric is divided by the number of "good requests" or "bad requests" that is observed for the metric defined in
MonitoredRequestCountMetric
.Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MonitoredRequestCountMetric
— required — (map
)This structure defines the metric that is used as the "good request" or "bad request" value for a request-based SLO. This value observed for the metric defined in
TotalRequestCountMetric
is divided by the number found forMonitoredRequestCountMetric
to determine the percentage of successful requests that this SLO tracks.GoodCountMetric
— (Array<map>
)If you want to count "good requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "good requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
BadCountMetric
— (Array<map>
)If you want to count "bad requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "bad requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— (Float
)This value is the threshold that the observed metric values of the SLI metric are compared to.
ComparisonOperator
— (String
)The arithmetic operation used when comparing the specified metric to the threshold.
Possible values include:"GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
EvaluationType
— (String
)Displays whether this is a period-based SLO or a request-based SLO.
Possible values include:"PeriodBased"
"RequestBased"
Goal
— required — (map
)This structure contains the attributes that determine the goal of an SLO. This includes the time period for evaluation and the attainment threshold.
Interval
— (map
)The time period used to evaluate the SLO. It can be either a calendar interval or rolling interval.
If you omit this parameter, a rolling interval of 7 days is used.
RollingInterval
— (map
)If the interval is a rolling interval, this structure contains the interval specifications.
DurationUnit
— required — (String
)Specifies the rolling interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each rolling interval. For example, if
Duration
is7
andDurationUnit
isDAY
, each rolling interval is seven days.
CalendarInterval
— (map
)If the interval is a calendar interval, this structure contains the interval specifications.
StartTime
— required — (Date
)The date and time when you want the first interval to start. Be sure to choose a time that configures the intervals the way that you want. For example, if you want weekly intervals starting on Mondays at 6 a.m., be sure to specify a start time that is a Monday at 6 a.m.
When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
As soon as one calendar interval ends, another automatically begins.
DurationUnit
— required — (String
)Specifies the calendar interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each calendar interval. For example, if
Duration
is1
andDurationUnit
isMONTH
, each interval is one month, aligned with the calendar.
AttainmentGoal
— (Float
)The threshold that determines if the goal is being met.
If this is a period-based SLO, the attainment goal is the percentage of good periods that meet the threshold requirements to the total periods within the interval. For example, an attainment goal of 99.9% means that within your interval, you are targeting 99.9% of the periods to be in healthy state.
If this is a request-based SLO, the attainment goal is the percentage of requests that must be successful to meet the attainment goal.
If you omit this parameter, 99 is used to represent 99% as the attainment goal.
WarningThreshold
— (Float
)The percentage of remaining budget over total budget that you want to get warnings for. If you omit this parameter, the default of 50.0 is used.
-
(AWS.Response)
—
Returns:
deleteServiceLevelObjective(params = {}, callback) ⇒ AWS.Request
Deletes the specified service level objective.
Service Reference:
Examples:
Calling the deleteServiceLevelObjective operation
var params = {
Id: 'STRING_VALUE' /* required */
};
applicationsignals.deleteServiceLevelObjective(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
Id
— (String
)The ARN or name of the service level objective to delete.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
getService(params = {}, callback) ⇒ AWS.Request
Returns information about a service discovered by Application Signals.
Service Reference:
Examples:
Calling the getService operation
var params = {
EndTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */
KeyAttributes: { /* required */
'<KeyAttributeName>': 'STRING_VALUE',
/* '<KeyAttributeName>': ... */
},
StartTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789 /* required */
};
applicationsignals.getService(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
StartTime
— (Date
)The start of the time period to retrieve information about. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
Your requested start time will be rounded to the nearest hour.
EndTime
— (Date
)The end of the time period to retrieve information about. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
Your requested start time will be rounded to the nearest hour.
KeyAttributes
— (map<String>
)Use this field to specify which service you want to retrieve information for. You must specify at least the
Type
,Name
, andEnvironment
attributes.This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:Service
— (map
)A structure containing information about the service.
KeyAttributes
— required — (map<String>
)This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
AttributeMaps
— (Array<map<String>>
)This structure contains one or more string-to-string maps that help identify this service. It can include platform attributes, application attributes, and telemetry attributes.
Platform attributes contain information the service's platform.
-
PlatformType
defines the hosted-in platform. -
EKS.Cluster
is the name of the Amazon EKS cluster. -
K8s.Cluster
is the name of the self-hosted Kubernetes cluster. -
K8s.Namespace
is the name of the Kubernetes namespace in either Amazon EKS or Kubernetes clusters. -
K8s.Workload
is the name of the Kubernetes workload in either Amazon EKS or Kubernetes clusters. -
K8s.Node
is the name of the Kubernetes node in either Amazon EKS or Kubernetes clusters. -
K8s.Pod
is the name of the Kubernetes pod in either Amazon EKS or Kubernetes clusters. -
EC2.AutoScalingGroup
is the name of the Amazon EC2 Auto Scaling group. -
EC2.InstanceId
is the ID of the Amazon EC2 instance. -
Host
is the name of the host, for all platform types.
Application attributes contain information about the application.
-
AWS.Application
is the application's name in Amazon Web Services Service Catalog AppRegistry. -
AWS.Application.ARN
is the application's ARN in Amazon Web Services Service Catalog AppRegistry.
Telemetry attributes contain telemetry information.
-
Telemetry.SDK
is the fingerprint of the OpenTelemetry SDK version for instrumented services. -
Telemetry.Agent
is the fingerprint of the agent used to collect and send telemetry data. -
Telemetry.Source
Specifies the point of application where the telemetry was collected or specifies what was used for the source of telemetry data.
-
MetricReferences
— required — (Array<map>
)An array of structures that each contain information about one metric associated with this service.
Namespace
— required — (String
)The namespace of the metric. For more information, see CloudWatchNamespaces.
MetricType
— required — (String
)Used to display the appropriate statistics in the CloudWatch console.
Dimensions
— (Array<map>
)An array of one or more dimensions that further define the metric. For more information, see CloudWatchDimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
MetricName
— required — (String
)The name of the metric.
LogGroupReferences
— (Array<map<String>>
)An array of string-to-string maps that each contain information about one log group associated with this service. Each string-to-string map includes the following fields:
-
"Type": "AWS::Resource"
-
"ResourceType": "AWS::Logs::LogGroup"
-
"Identifier": "name-of-log-group"
-
StartTime
— (Date
)The start time of the data included in the response. In a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
.This displays the time that Application Signals used for the request. It might not match your request exactly, because it was rounded to the nearest hour.
EndTime
— (Date
)The end time of the data included in the response. In a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
.This displays the time that Application Signals used for the request. It might not match your request exactly, because it was rounded to the nearest hour.
LogGroupReferences
— (Array<map<String>>
)An array of string-to-string maps that each contain information about one log group associated with this service. Each string-to-string map includes the following fields:
-
"Type": "AWS::Resource"
-
"ResourceType": "AWS::Logs::LogGroup"
-
"Identifier": "name-of-log-group"
-
-
(AWS.Response)
—
Returns:
getServiceLevelObjective(params = {}, callback) ⇒ AWS.Request
Returns information about one SLO created in the account.
Service Reference:
Examples:
Calling the getServiceLevelObjective operation
var params = {
Id: 'STRING_VALUE' /* required */
};
applicationsignals.getServiceLevelObjective(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
Id
— (String
)The ARN or name of the SLO that you want to retrieve information about. You can find the ARNs of SLOs by using the ListServiceLevelObjectives operation.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:Slo
— (map
)A structure containing the information about the SLO.
Arn
— required — (String
)The ARN of this SLO.
Name
— required — (String
)The name of this SLO.
Description
— (String
)The description that you created for this SLO.
CreatedTime
— required — (Date
)The date and time that this SLO was created. When used in a raw HTTP Query API, it is formatted as
yyyy-MM-dd'T'HH:mm:ss
. For example,2019-07-01T23:59:59
.LastUpdatedTime
— required — (Date
)The time that this SLO was most recently updated. When used in a raw HTTP Query API, it is formatted as
yyyy-MM-dd'T'HH:mm:ss
. For example,2019-07-01T23:59:59
.Sli
— (map
)A structure containing information about the performance metric that this SLO monitors, if this is a period-based SLO.
SliMetric
— required — (map
)A structure that contains information about the metric that the SLO monitors.
KeyAttributes
— (map<String>
)This is a string-to-string map that contains information about the type of object that this SLO is related to. It can include the following fields.
-
Type
designates the type of object that this SLO is related to. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO monitors a specific operation of the service, this field displays that operation name.
MetricType
— (String
)If the SLO monitors either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, this field displays which of those metrics is used."LATENCY"
"AVAILABILITY"
MetricDataQueries
— required — (Array<map>
)If this SLO monitors a CloudWatch metric or the result of a CloudWatch metric math expression, this structure includes the information about that metric or expression.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— required — (Float
)The value that the SLI metric is compared to.
ComparisonOperator
— required — (String
)The arithmetic operation used when comparing the specified metric to the threshold.
Possible values include:"GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
RequestBasedSli
— (map
)A structure containing information about the performance metric that this SLO monitors, if this is a request-based SLO.
RequestBasedSliMetric
— required — (map
)A structure that contains information about the metric that the SLO monitors.
KeyAttributes
— (map<String>
)This is a string-to-string map that contains information about the type of object that this SLO is related to. It can include the following fields.
-
Type
designates the type of object that this SLO is related to. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO monitors a specific operation of the service, this field displays that operation name.
MetricType
— (String
)If the SLO monitors either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, this field displays which of those metrics is used."LATENCY"
"AVAILABILITY"
TotalRequestCountMetric
— required — (Array<map>
)This structure defines the metric that is used as the "total requests" number for a request-based SLO. The number observed for this metric is divided by the number of "good requests" or "bad requests" that is observed for the metric defined in
MonitoredRequestCountMetric
.Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MonitoredRequestCountMetric
— required — (map
)This structure defines the metric that is used as the "good request" or "bad request" value for a request-based SLO. This value observed for the metric defined in
TotalRequestCountMetric
is divided by the number found forMonitoredRequestCountMetric
to determine the percentage of successful requests that this SLO tracks.GoodCountMetric
— (Array<map>
)If you want to count "good requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "good requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
BadCountMetric
— (Array<map>
)If you want to count "bad requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "bad requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— (Float
)This value is the threshold that the observed metric values of the SLI metric are compared to.
ComparisonOperator
— (String
)The arithmetic operation used when comparing the specified metric to the threshold.
Possible values include:"GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
EvaluationType
— (String
)Displays whether this is a period-based SLO or a request-based SLO.
Possible values include:"PeriodBased"
"RequestBased"
Goal
— required — (map
)This structure contains the attributes that determine the goal of an SLO. This includes the time period for evaluation and the attainment threshold.
Interval
— (map
)The time period used to evaluate the SLO. It can be either a calendar interval or rolling interval.
If you omit this parameter, a rolling interval of 7 days is used.
RollingInterval
— (map
)If the interval is a rolling interval, this structure contains the interval specifications.
DurationUnit
— required — (String
)Specifies the rolling interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each rolling interval. For example, if
Duration
is7
andDurationUnit
isDAY
, each rolling interval is seven days.
CalendarInterval
— (map
)If the interval is a calendar interval, this structure contains the interval specifications.
StartTime
— required — (Date
)The date and time when you want the first interval to start. Be sure to choose a time that configures the intervals the way that you want. For example, if you want weekly intervals starting on Mondays at 6 a.m., be sure to specify a start time that is a Monday at 6 a.m.
When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
As soon as one calendar interval ends, another automatically begins.
DurationUnit
— required — (String
)Specifies the calendar interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each calendar interval. For example, if
Duration
is1
andDurationUnit
isMONTH
, each interval is one month, aligned with the calendar.
AttainmentGoal
— (Float
)The threshold that determines if the goal is being met.
If this is a period-based SLO, the attainment goal is the percentage of good periods that meet the threshold requirements to the total periods within the interval. For example, an attainment goal of 99.9% means that within your interval, you are targeting 99.9% of the periods to be in healthy state.
If this is a request-based SLO, the attainment goal is the percentage of requests that must be successful to meet the attainment goal.
If you omit this parameter, 99 is used to represent 99% as the attainment goal.
WarningThreshold
— (Float
)The percentage of remaining budget over total budget that you want to get warnings for. If you omit this parameter, the default of 50.0 is used.
-
(AWS.Response)
—
Returns:
listServiceDependencies(params = {}, callback) ⇒ AWS.Request
Returns a list of service dependencies of the service that you specify. A dependency is an infrastructure component that an operation of this service connects with. Dependencies can include Amazon Web Services services, Amazon Web Services resources, and third-party services.
Service Reference:
Examples:
Calling the listServiceDependencies operation
var params = {
EndTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */
KeyAttributes: { /* required */
'<KeyAttributeName>': 'STRING_VALUE',
/* '<KeyAttributeName>': ... */
},
StartTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */
MaxResults: 'NUMBER_VALUE',
NextToken: 'STRING_VALUE'
};
applicationsignals.listServiceDependencies(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
StartTime
— (Date
)The start of the time period to retrieve information about. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
Your requested start time will be rounded to the nearest hour.
EndTime
— (Date
)The end of the time period to retrieve information about. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
Your requested end time will be rounded to the nearest hour.
KeyAttributes
— (map<String>
)Use this field to specify which service you want to retrieve information for. You must specify at least the
Type
,Name
, andEnvironment
attributes.This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
MaxResults
— (Integer
)The maximum number of results to return in one operation. If you omit this parameter, the default of 50 is used.
NextToken
— (String
)Include this value, if it was returned by the previous operation, to get the next set of service dependencies.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:StartTime
— (Date
)The start of the time period that the returned information applies to. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
This displays the time that Application Signals used for the request. It might not match your request exactly, because it was rounded to the nearest hour.
EndTime
— (Date
)The end of the time period that the returned information applies to. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
This displays the time that Application Signals used for the request. It might not match your request exactly, because it was rounded to the nearest hour.
ServiceDependencies
— (Array<map>
)An array, where each object in the array contains information about one of the dependencies of this service.
OperationName
— required — (String
)The name of the operation in this service that calls the dependency.
DependencyKeyAttributes
— required — (map<String>
)This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
DependencyOperationName
— required — (String
)The name of the called operation in the dependency.
MetricReferences
— required — (Array<map>
)An array of structures that each contain information about one metric associated with this service dependency that was discovered by Application Signals.
Namespace
— required — (String
)The namespace of the metric. For more information, see CloudWatchNamespaces.
MetricType
— required — (String
)Used to display the appropriate statistics in the CloudWatch console.
Dimensions
— (Array<map>
)An array of one or more dimensions that further define the metric. For more information, see CloudWatchDimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
MetricName
— required — (String
)The name of the metric.
NextToken
— (String
)Include this value in your next use of this API to get next set of service dependencies.
-
(AWS.Response)
—
Returns:
listServiceDependents(params = {}, callback) ⇒ AWS.Request
Returns the list of dependents that invoked the specified service during the provided time range. Dependents include other services, CloudWatch Synthetics canaries, and clients that are instrumented with CloudWatch RUM app monitors.
Service Reference:
Examples:
Calling the listServiceDependents operation
var params = {
EndTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */
KeyAttributes: { /* required */
'<KeyAttributeName>': 'STRING_VALUE',
/* '<KeyAttributeName>': ... */
},
StartTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */
MaxResults: 'NUMBER_VALUE',
NextToken: 'STRING_VALUE'
};
applicationsignals.listServiceDependents(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
StartTime
— (Date
)The start of the time period to retrieve information about. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
Your requested start time will be rounded to the nearest hour.
EndTime
— (Date
)The end of the time period to retrieve information about. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
Your requested start time will be rounded to the nearest hour.
KeyAttributes
— (map<String>
)Use this field to specify which service you want to retrieve information for. You must specify at least the
Type
,Name
, andEnvironment
attributes.This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
MaxResults
— (Integer
)The maximum number of results to return in one operation. If you omit this parameter, the default of 50 is used.
NextToken
— (String
)Include this value, if it was returned by the previous operation, to get the next set of service dependents.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:StartTime
— (Date
)The start of the time period that the returned information applies to. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
This displays the time that Application Signals used for the request. It might not match your request exactly, because it was rounded to the nearest hour.
EndTime
— (Date
)The end of the time period that the returned information applies to. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
This displays the time that Application Signals used for the request. It might not match your request exactly, because it was rounded to the nearest hour.
ServiceDependents
— (Array<map>
)An array, where each object in the array contains information about one of the dependents of this service.
OperationName
— (String
)If the invoked entity is an operation on an entity, the name of that dependent operation is displayed here.
DependentKeyAttributes
— required — (map<String>
)This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
DependentOperationName
— (String
)If the dependent invoker was a service that invoked it from an operation, the name of that dependent operation is displayed here.
MetricReferences
— required — (Array<map>
)An array of structures that each contain information about one metric associated with this service dependent that was discovered by Application Signals.
Namespace
— required — (String
)The namespace of the metric. For more information, see CloudWatchNamespaces.
MetricType
— required — (String
)Used to display the appropriate statistics in the CloudWatch console.
Dimensions
— (Array<map>
)An array of one or more dimensions that further define the metric. For more information, see CloudWatchDimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
MetricName
— required — (String
)The name of the metric.
NextToken
— (String
)Include this value in your next use of this API to get next set of service dependents.
-
(AWS.Response)
—
Returns:
listServiceLevelObjectives(params = {}, callback) ⇒ AWS.Request
Returns a list of SLOs created in this account.
Service Reference:
Examples:
Calling the listServiceLevelObjectives operation
var params = {
KeyAttributes: {
'<KeyAttributeName>': 'STRING_VALUE',
/* '<KeyAttributeName>': ... */
},
MaxResults: 'NUMBER_VALUE',
NextToken: 'STRING_VALUE',
OperationName: 'STRING_VALUE'
};
applicationsignals.listServiceLevelObjectives(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
KeyAttributes
— (map<String>
)You can use this optional field to specify which services you want to retrieve SLO information for.
This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)The name of the operation that this SLO is associated with.
MaxResults
— (Integer
)The maximum number of results to return in one operation. If you omit this parameter, the default of 50 is used.
NextToken
— (String
)Include this value, if it was returned by the previous operation, to get the next set of service level objectives.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:SloSummaries
— (Array<map>
)An array of structures, where each structure contains information about one SLO.
Arn
— required — (String
)The ARN of this service level objective.
Name
— required — (String
)The name of the service level objective.
KeyAttributes
— (map<String>
)This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this service level objective is for. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If this service level objective is specific to a single operation, this field displays the name of that operation.
CreatedTime
— (Date
)The date and time that this service level objective was created. It is expressed as the number of milliseconds since Jan 1, 1970 00:00:00 UTC.
NextToken
— (String
)Include this value in your next use of this API to get next set of service level objectives.
-
(AWS.Response)
—
Returns:
listServiceOperations(params = {}, callback) ⇒ AWS.Request
Returns a list of the operations of this service that have been discovered by Application Signals. Only the operations that were invoked during the specified time range are returned.
Service Reference:
Examples:
Calling the listServiceOperations operation
var params = {
EndTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */
KeyAttributes: { /* required */
'<KeyAttributeName>': 'STRING_VALUE',
/* '<KeyAttributeName>': ... */
},
StartTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */
MaxResults: 'NUMBER_VALUE',
NextToken: 'STRING_VALUE'
};
applicationsignals.listServiceOperations(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
StartTime
— (Date
)The start of the time period to retrieve information about. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
Your requested start time will be rounded to the nearest hour.
EndTime
— (Date
)The end of the time period to retrieve information about. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
Your requested end time will be rounded to the nearest hour.
KeyAttributes
— (map<String>
)Use this field to specify which service you want to retrieve information for. You must specify at least the
Type
,Name
, andEnvironment
attributes.This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
MaxResults
— (Integer
)The maximum number of results to return in one operation. If you omit this parameter, the default of 50 is used.
NextToken
— (String
)Include this value, if it was returned by the previous operation, to get the next set of service operations.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:StartTime
— (Date
)The start of the time period that the returned information applies to. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
This displays the time that Application Signals used for the request. It might not match your request exactly, because it was rounded to the nearest hour.
EndTime
— (Date
)The end of the time period that the returned information applies to. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
This displays the time that Application Signals used for the request. It might not match your request exactly, because it was rounded to the nearest hour.
ServiceOperations
— (Array<map>
)An array of structures that each contain information about one operation of this service.
Name
— required — (String
)The name of the operation, discovered by Application Signals.
MetricReferences
— required — (Array<map>
)An array of structures that each contain information about one metric associated with this service operation that was discovered by Application Signals.
Namespace
— required — (String
)The namespace of the metric. For more information, see CloudWatchNamespaces.
MetricType
— required — (String
)Used to display the appropriate statistics in the CloudWatch console.
Dimensions
— (Array<map>
)An array of one or more dimensions that further define the metric. For more information, see CloudWatchDimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
MetricName
— required — (String
)The name of the metric.
NextToken
— (String
)Include this value in your next use of this API to get next set of service operations.
-
(AWS.Response)
—
Returns:
listServices(params = {}, callback) ⇒ AWS.Request
Returns a list of services that have been discovered by Application Signals. A service represents a minimum logical and transactional unit that completes a business function. Services are discovered through Application Signals instrumentation.
Service Reference:
Examples:
Calling the listServices operation
var params = {
EndTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */
StartTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789, /* required */
MaxResults: 'NUMBER_VALUE',
NextToken: 'STRING_VALUE'
};
applicationsignals.listServices(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
StartTime
— (Date
)The start of the time period to retrieve information about. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
Your requested start time will be rounded to the nearest hour.
EndTime
— (Date
)The end of the time period to retrieve information about. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
Your requested start time will be rounded to the nearest hour.
MaxResults
— (Integer
)The maximum number of results to return in one operation. If you omit this parameter, the default of 50 is used.
NextToken
— (String
)Include this value, if it was returned by the previous operation, to get the next set of services.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:StartTime
— (Date
)The start of the time period that the returned information applies to. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
This displays the time that Application Signals used for the request. It might not match your request exactly, because it was rounded to the nearest hour.
EndTime
— (Date
)The end of the time period that the returned information applies to. When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
This displays the time that Application Signals used for the request. It might not match your request exactly, because it was rounded to the nearest hour.
ServiceSummaries
— (Array<map>
)An array of structures, where each structure contains some information about a service. To get complete information about a service, use GetService.
KeyAttributes
— required — (map<String>
)This is a string-to-string map that help identify the objects discovered by Application Signals. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
AttributeMaps
— (Array<map<String>>
)This structure contains one or more string-to-string maps that help identify this service. It can include platform attributes, application attributes, and telemetry attributes.
Platform attributes contain information the service's platform.
-
PlatformType
defines the hosted-in platform. -
EKS.Cluster
is the name of the Amazon EKS cluster. -
K8s.Cluster
is the name of the self-hosted Kubernetes cluster. -
K8s.Namespace
is the name of the Kubernetes namespace in either Amazon EKS or Kubernetes clusters. -
K8s.Workload
is the name of the Kubernetes workload in either Amazon EKS or Kubernetes clusters. -
K8s.Node
is the name of the Kubernetes node in either Amazon EKS or Kubernetes clusters. -
K8s.Pod
is the name of the Kubernetes pod in either Amazon EKS or Kubernetes clusters. -
EC2.AutoScalingGroup
is the name of the Amazon EC2 Auto Scaling group. -
EC2.InstanceId
is the ID of the Amazon EC2 instance. -
Host
is the name of the host, for all platform types.
Application attributes contain information about the application.
-
AWS.Application
is the application's name in Amazon Web Services Service Catalog AppRegistry. -
AWS.Application.ARN
is the application's ARN in Amazon Web Services Service Catalog AppRegistry.
Telemetry attributes contain telemetry information.
-
Telemetry.SDK
is the fingerprint of the OpenTelemetry SDK version for instrumented services. -
Telemetry.Agent
is the fingerprint of the agent used to collect and send telemetry data. -
Telemetry.Source
Specifies the point of application where the telemetry was collected or specifies what was used for the source of telemetry data.
-
MetricReferences
— required — (Array<map>
)An array of structures that each contain information about one metric associated with this service.
Namespace
— required — (String
)The namespace of the metric. For more information, see CloudWatchNamespaces.
MetricType
— required — (String
)Used to display the appropriate statistics in the CloudWatch console.
Dimensions
— (Array<map>
)An array of one or more dimensions that further define the metric. For more information, see CloudWatchDimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
MetricName
— required — (String
)The name of the metric.
NextToken
— (String
)Include this value in your next use of this API to get next set of services.
-
(AWS.Response)
—
Returns:
listTagsForResource(params = {}, callback) ⇒ AWS.Request
Displays the tags associated with a CloudWatch resource. Tags can be assigned to service level objectives.
Service Reference:
Examples:
Calling the listTagsForResource operation
var params = {
ResourceArn: 'STRING_VALUE' /* required */
};
applicationsignals.listTagsForResource(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
ResourceArn
— (String
)The Amazon Resource Name (ARN) of the CloudWatch resource that you want to view tags for.
The ARN format of an Application Signals SLO is
arn:aws:cloudwatch:Region:account-id:slo:slo-name
For more information about ARN format, see Resource Types Defined by Amazon CloudWatch in the Amazon Web Services General Reference.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:Tags
— (Array<map>
)The list of tag keys and values associated with the resource you specified.
Key
— required — (String
)A string that you can use to assign a value. The combination of tag keys and values can help you organize and categorize your resources.
Value
— required — (String
)The value for the specified tag key.
-
(AWS.Response)
—
Returns:
startDiscovery(params = {}, callback) ⇒ AWS.Request
Enables this Amazon Web Services account to be able to use CloudWatch Application Signals by creating the AWSServiceRoleForCloudWatchApplicationSignals service-linked role. This service- linked role has the following permissions:
-
xray:GetServiceGraph
-
logs:StartQuery
-
logs:GetQueryResults
-
cloudwatch:GetMetricData
-
cloudwatch:ListMetrics
-
tag:GetResources
-
autoscaling:DescribeAutoScalingGroups
After completing this step, you still need to instrument your Java and Python applications to send data to Application Signals. For more information, see Enabling Application Signals.
Service Reference:
Examples:
Calling the startDiscovery operation
var params = {
};
applicationsignals.startDiscovery(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
- params (Object) (defaults to: {})
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
tagResource(params = {}, callback) ⇒ AWS.Request
Assigns one or more tags (key-value pairs) to the specified CloudWatch resource, such as a service level objective.
Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only resources with certain tag values.
Tags don't have any semantic meaning to Amazon Web Services and are interpreted strictly as strings of characters.
You can use the TagResource
action with an alarm that already has tags. If you specify a new tag key for the alarm, this tag is appended to the list of tags associated with the alarm. If you specify a tag key that is already associated with the alarm, the new tag value that you specify replaces the previous value for that tag.
You can associate as many as 50 tags with a CloudWatch resource.
Service Reference:
Examples:
Calling the tagResource operation
var params = {
ResourceArn: 'STRING_VALUE', /* required */
Tags: [ /* required */
{
Key: 'STRING_VALUE', /* required */
Value: 'STRING_VALUE' /* required */
},
/* more items */
]
};
applicationsignals.tagResource(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
ResourceArn
— (String
)The Amazon Resource Name (ARN) of the CloudWatch resource that you want to set tags for.
The ARN format of an Application Signals SLO is
arn:aws:cloudwatch:Region:account-id:slo:slo-name
For more information about ARN format, see Resource Types Defined by Amazon CloudWatch in the Amazon Web Services General Reference.
Tags
— (Array<map>
)The list of key-value pairs to associate with the alarm.
Key
— required — (String
)A string that you can use to assign a value. The combination of tag keys and values can help you organize and categorize your resources.
Value
— required — (String
)The value for the specified tag key.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
untagResource(params = {}, callback) ⇒ AWS.Request
Removes one or more tags from the specified resource.
Service Reference:
Examples:
Calling the untagResource operation
var params = {
ResourceArn: 'STRING_VALUE', /* required */
TagKeys: [ /* required */
'STRING_VALUE',
/* more items */
]
};
applicationsignals.untagResource(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
ResourceArn
— (String
)The Amazon Resource Name (ARN) of the CloudWatch resource that you want to delete tags from.
The ARN format of an Application Signals SLO is
arn:aws:cloudwatch:Region:account-id:slo:slo-name
For more information about ARN format, see Resource Types Defined by Amazon CloudWatch in the Amazon Web Services General Reference.
TagKeys
— (Array<String>
)The list of tag keys to remove from the resource.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs.
-
(AWS.Response)
—
Returns:
updateServiceLevelObjective(params = {}, callback) ⇒ AWS.Request
Updates an existing service level objective (SLO). If you omit parameters, the previous values of those parameters are retained.
You cannot change from a period-based SLO to a request-based SLO, or change from a request-based SLO to a period-based SLO.
Service Reference:
Examples:
Calling the updateServiceLevelObjective operation
var params = {
Id: 'STRING_VALUE', /* required */
Description: 'STRING_VALUE',
Goal: {
AttainmentGoal: 'NUMBER_VALUE',
Interval: {
CalendarInterval: {
Duration: 'NUMBER_VALUE', /* required */
DurationUnit: MINUTE | HOUR | DAY | MONTH, /* required */
StartTime: new Date || 'Wed Dec 31 1969 16:00:00 GMT-0800 (PST)' || 123456789 /* required */
},
RollingInterval: {
Duration: 'NUMBER_VALUE', /* required */
DurationUnit: MINUTE | HOUR | DAY | MONTH /* required */
}
},
WarningThreshold: 'NUMBER_VALUE'
},
RequestBasedSliConfig: {
RequestBasedSliMetricConfig: { /* required */
KeyAttributes: {
'<KeyAttributeName>': 'STRING_VALUE',
/* '<KeyAttributeName>': ... */
},
MetricType: LATENCY | AVAILABILITY,
MonitoredRequestCountMetric: {
BadCountMetric: [
{
Id: 'STRING_VALUE', /* required */
AccountId: 'STRING_VALUE',
Expression: 'STRING_VALUE',
Label: 'STRING_VALUE',
MetricStat: {
Metric: { /* required */
Dimensions: [
{
Name: 'STRING_VALUE', /* required */
Value: 'STRING_VALUE' /* required */
},
/* more items */
],
MetricName: 'STRING_VALUE',
Namespace: 'STRING_VALUE'
},
Period: 'NUMBER_VALUE', /* required */
Stat: 'STRING_VALUE', /* required */
Unit: Microseconds | Milliseconds | Seconds | Bytes | Kilobytes | Megabytes | Gigabytes | Terabytes | Bits | Kilobits | Megabits | Gigabits | Terabits | Percent | Count | Bytes/Second | Kilobytes/Second | Megabytes/Second | Gigabytes/Second | Terabytes/Second | Bits/Second | Kilobits/Second | Megabits/Second | Gigabits/Second | Terabits/Second | Count/Second | None
},
Period: 'NUMBER_VALUE',
ReturnData: true || false
},
/* more items */
],
GoodCountMetric: [
{
Id: 'STRING_VALUE', /* required */
AccountId: 'STRING_VALUE',
Expression: 'STRING_VALUE',
Label: 'STRING_VALUE',
MetricStat: {
Metric: { /* required */
Dimensions: [
{
Name: 'STRING_VALUE', /* required */
Value: 'STRING_VALUE' /* required */
},
/* more items */
],
MetricName: 'STRING_VALUE',
Namespace: 'STRING_VALUE'
},
Period: 'NUMBER_VALUE', /* required */
Stat: 'STRING_VALUE', /* required */
Unit: Microseconds | Milliseconds | Seconds | Bytes | Kilobytes | Megabytes | Gigabytes | Terabytes | Bits | Kilobits | Megabits | Gigabits | Terabits | Percent | Count | Bytes/Second | Kilobytes/Second | Megabytes/Second | Gigabytes/Second | Terabytes/Second | Bits/Second | Kilobits/Second | Megabits/Second | Gigabits/Second | Terabits/Second | Count/Second | None
},
Period: 'NUMBER_VALUE',
ReturnData: true || false
},
/* more items */
]
},
OperationName: 'STRING_VALUE',
TotalRequestCountMetric: [
{
Id: 'STRING_VALUE', /* required */
AccountId: 'STRING_VALUE',
Expression: 'STRING_VALUE',
Label: 'STRING_VALUE',
MetricStat: {
Metric: { /* required */
Dimensions: [
{
Name: 'STRING_VALUE', /* required */
Value: 'STRING_VALUE' /* required */
},
/* more items */
],
MetricName: 'STRING_VALUE',
Namespace: 'STRING_VALUE'
},
Period: 'NUMBER_VALUE', /* required */
Stat: 'STRING_VALUE', /* required */
Unit: Microseconds | Milliseconds | Seconds | Bytes | Kilobytes | Megabytes | Gigabytes | Terabytes | Bits | Kilobits | Megabits | Gigabits | Terabits | Percent | Count | Bytes/Second | Kilobytes/Second | Megabytes/Second | Gigabytes/Second | Terabytes/Second | Bits/Second | Kilobits/Second | Megabits/Second | Gigabits/Second | Terabits/Second | Count/Second | None
},
Period: 'NUMBER_VALUE',
ReturnData: true || false
},
/* more items */
]
},
ComparisonOperator: GreaterThanOrEqualTo | GreaterThan | LessThan | LessThanOrEqualTo,
MetricThreshold: 'NUMBER_VALUE'
},
SliConfig: {
ComparisonOperator: GreaterThanOrEqualTo | GreaterThan | LessThan | LessThanOrEqualTo, /* required */
MetricThreshold: 'NUMBER_VALUE', /* required */
SliMetricConfig: { /* required */
KeyAttributes: {
'<KeyAttributeName>': 'STRING_VALUE',
/* '<KeyAttributeName>': ... */
},
MetricDataQueries: [
{
Id: 'STRING_VALUE', /* required */
AccountId: 'STRING_VALUE',
Expression: 'STRING_VALUE',
Label: 'STRING_VALUE',
MetricStat: {
Metric: { /* required */
Dimensions: [
{
Name: 'STRING_VALUE', /* required */
Value: 'STRING_VALUE' /* required */
},
/* more items */
],
MetricName: 'STRING_VALUE',
Namespace: 'STRING_VALUE'
},
Period: 'NUMBER_VALUE', /* required */
Stat: 'STRING_VALUE', /* required */
Unit: Microseconds | Milliseconds | Seconds | Bytes | Kilobytes | Megabytes | Gigabytes | Terabytes | Bits | Kilobits | Megabits | Gigabits | Terabits | Percent | Count | Bytes/Second | Kilobytes/Second | Megabytes/Second | Gigabytes/Second | Terabytes/Second | Bits/Second | Kilobits/Second | Megabits/Second | Gigabits/Second | Terabits/Second | Count/Second | None
},
Period: 'NUMBER_VALUE',
ReturnData: true || false
},
/* more items */
],
MetricType: LATENCY | AVAILABILITY,
OperationName: 'STRING_VALUE',
PeriodSeconds: 'NUMBER_VALUE',
Statistic: 'STRING_VALUE'
}
}
};
applicationsignals.updateServiceLevelObjective(params, function(err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Parameters:
-
params
(Object)
(defaults to: {})
—
Id
— (String
)The Amazon Resource Name (ARN) or name of the service level objective that you want to update.
Description
— (String
)An optional description for the SLO.
SliConfig
— (map
)If this SLO is a period-based SLO, this structure defines the information about what performance metric this SLO will monitor.
SliMetricConfig
— required — (map
)Use this structure to specify the metric to be used for the SLO.
KeyAttributes
— (map<String>
)If this SLO is related to a metric collected by Application Signals, you must use this field to specify which service the SLO metric is related to. To do so, you must specify at least the
Type
,Name
, andEnvironment
attributes.This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO is to monitor a specific operation of the service, use this field to specify the name of that operation.
MetricType
— (String
)If the SLO is to monitor either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, use this field to specify which of those metrics is used."LATENCY"
"AVAILABILITY"
Statistic
— (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
PeriodSeconds
— (Integer
)The number of seconds to use as the period for SLO evaluation. Your application's performance is compared to the SLI during each period. For each period, the application is determined to have either achieved or not achieved the necessary performance.
MetricDataQueries
— (Array<map>
)If this SLO monitors a CloudWatch metric or the result of a CloudWatch metric math expression, use this structure to specify that metric or expression.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— required — (Float
)This parameter is used only when a request-based SLO tracks the
Latency
metric. Specify the threshold value that the observedLatency
metric values are to be compared to.ComparisonOperator
— required — (String
)The arithmetic operation to use when comparing the specified metric to the threshold.
Possible values include:"GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
RequestBasedSliConfig
— (map
)If this SLO is a request-based SLO, this structure defines the information about what performance metric this SLO will monitor.
You can't specify both
SliConfig
andRequestBasedSliConfig
in the same operation.RequestBasedSliMetricConfig
— required — (map
)Use this structure to specify the metric to be used for the SLO.
KeyAttributes
— (map<String>
)If this SLO is related to a metric collected by Application Signals, you must use this field to specify which service the SLO metric is related to. To do so, you must specify at least the
Type
,Name
, andEnvironment
attributes.This is a string-to-string map. It can include the following fields.
-
Type
designates the type of object this is. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO is to monitor a specific operation of the service, use this field to specify the name of that operation.
MetricType
— (String
)If the SLO is to monitor either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, use this field to specify which of those metrics is used."LATENCY"
"AVAILABILITY"
TotalRequestCountMetric
— (Array<map>
)Use this structure to define the metric that you want to use as the "total requests" number for a request-based SLO. This result will be divided by the "good request" or "bad request" value defined in
MonitoredRequestCountMetric
.Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MonitoredRequestCountMetric
— (map
)Use this structure to define the metric that you want to use as the "good request" or "bad request" value for a request-based SLO. This value observed for the metric defined in
TotalRequestCountMetric
will be divided by the number found forMonitoredRequestCountMetric
to determine the percentage of successful requests that this SLO tracks.GoodCountMetric
— (Array<map>
)If you want to count "good requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "good requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
BadCountMetric
— (Array<map>
)If you want to count "bad requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "bad requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— (Float
)The value that the SLI metric is compared to. This parameter is required if this SLO is tracking the
Latency
metric.ComparisonOperator
— (String
)The arithmetic operation to use when comparing the specified metric to the threshold. This parameter is required if this SLO is tracking the
Possible values include:Latency
metric."GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
Goal
— (map
)A structure that contains the attributes that determine the goal of the SLO. This includes the time period for evaluation and the attainment threshold.
Interval
— (map
)The time period used to evaluate the SLO. It can be either a calendar interval or rolling interval.
If you omit this parameter, a rolling interval of 7 days is used.
RollingInterval
— (map
)If the interval is a rolling interval, this structure contains the interval specifications.
DurationUnit
— required — (String
)Specifies the rolling interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each rolling interval. For example, if
Duration
is7
andDurationUnit
isDAY
, each rolling interval is seven days.
CalendarInterval
— (map
)If the interval is a calendar interval, this structure contains the interval specifications.
StartTime
— required — (Date
)The date and time when you want the first interval to start. Be sure to choose a time that configures the intervals the way that you want. For example, if you want weekly intervals starting on Mondays at 6 a.m., be sure to specify a start time that is a Monday at 6 a.m.
When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
As soon as one calendar interval ends, another automatically begins.
DurationUnit
— required — (String
)Specifies the calendar interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each calendar interval. For example, if
Duration
is1
andDurationUnit
isMONTH
, each interval is one month, aligned with the calendar.
AttainmentGoal
— (Float
)The threshold that determines if the goal is being met.
If this is a period-based SLO, the attainment goal is the percentage of good periods that meet the threshold requirements to the total periods within the interval. For example, an attainment goal of 99.9% means that within your interval, you are targeting 99.9% of the periods to be in healthy state.
If this is a request-based SLO, the attainment goal is the percentage of requests that must be successful to meet the attainment goal.
If you omit this parameter, 99 is used to represent 99% as the attainment goal.
WarningThreshold
— (Float
)The percentage of remaining budget over total budget that you want to get warnings for. If you omit this parameter, the default of 50.0 is used.
Callback (callback):
-
function(err, data) { ... }
Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.
Context (this):
-
(AWS.Response)
—
the response object containing error, data properties, and the original request object.
Parameters:
-
err
(Error)
—
the error object returned from the request. Set to
null
if the request is successful. -
data
(Object)
—
the de-serialized data returned from the request. Set to
null
if a request error occurs. Thedata
object has the following properties:Slo
— (map
)A structure that contains information about the SLO that you just updated.
Arn
— required — (String
)The ARN of this SLO.
Name
— required — (String
)The name of this SLO.
Description
— (String
)The description that you created for this SLO.
CreatedTime
— required — (Date
)The date and time that this SLO was created. When used in a raw HTTP Query API, it is formatted as
yyyy-MM-dd'T'HH:mm:ss
. For example,2019-07-01T23:59:59
.LastUpdatedTime
— required — (Date
)The time that this SLO was most recently updated. When used in a raw HTTP Query API, it is formatted as
yyyy-MM-dd'T'HH:mm:ss
. For example,2019-07-01T23:59:59
.Sli
— (map
)A structure containing information about the performance metric that this SLO monitors, if this is a period-based SLO.
SliMetric
— required — (map
)A structure that contains information about the metric that the SLO monitors.
KeyAttributes
— (map<String>
)This is a string-to-string map that contains information about the type of object that this SLO is related to. It can include the following fields.
-
Type
designates the type of object that this SLO is related to. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO monitors a specific operation of the service, this field displays that operation name.
MetricType
— (String
)If the SLO monitors either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, this field displays which of those metrics is used."LATENCY"
"AVAILABILITY"
MetricDataQueries
— required — (Array<map>
)If this SLO monitors a CloudWatch metric or the result of a CloudWatch metric math expression, this structure includes the information about that metric or expression.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— required — (Float
)The value that the SLI metric is compared to.
ComparisonOperator
— required — (String
)The arithmetic operation used when comparing the specified metric to the threshold.
Possible values include:"GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
RequestBasedSli
— (map
)A structure containing information about the performance metric that this SLO monitors, if this is a request-based SLO.
RequestBasedSliMetric
— required — (map
)A structure that contains information about the metric that the SLO monitors.
KeyAttributes
— (map<String>
)This is a string-to-string map that contains information about the type of object that this SLO is related to. It can include the following fields.
-
Type
designates the type of object that this SLO is related to. -
ResourceType
specifies the type of the resource. This field is used only when the value of theType
field isResource
orAWS::Resource
. -
Name
specifies the name of the object. This is used only if the value of theType
field isService
,RemoteService
, orAWS::Service
. -
Identifier
identifies the resource objects of this resource. This is used only if the value of theType
field isResource
orAWS::Resource
. -
Environment
specifies the location where this object is hosted, or what it belongs to.
-
OperationName
— (String
)If the SLO monitors a specific operation of the service, this field displays that operation name.
MetricType
— (String
)If the SLO monitors either the
Possible values include:LATENCY
orAVAILABILITY
metric that Application Signals collects, this field displays which of those metrics is used."LATENCY"
"AVAILABILITY"
TotalRequestCountMetric
— required — (Array<map>
)This structure defines the metric that is used as the "total requests" number for a request-based SLO. The number observed for this metric is divided by the number of "good requests" or "bad requests" that is observed for the metric defined in
MonitoredRequestCountMetric
.Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MonitoredRequestCountMetric
— required — (map
)This structure defines the metric that is used as the "good request" or "bad request" value for a request-based SLO. This value observed for the metric defined in
TotalRequestCountMetric
is divided by the number found forMonitoredRequestCountMetric
to determine the percentage of successful requests that this SLO tracks.GoodCountMetric
— (Array<map>
)If you want to count "good requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "good requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
BadCountMetric
— (Array<map>
)If you want to count "bad requests" to determine the percentage of successful requests for this request-based SLO, specify the metric to use as "bad requests" in this structure.
Id
— required — (String
)A short name used to tie this object to the results in the response. This
Id
must be unique within aMetricDataQueries
array. If you are performing math expressions on this set of data, this name represents that data and can serve as a variable in the metric math expression. The valid characters are letters, numbers, and underscore. The first character must be a lowercase letter.MetricStat
— (map
)A metric to be used directly for the SLO, or to be used in the math expression that will be used for the SLO.
Within one
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Metric
— required — (map
)The metric to use as the service level indicator, including the metric name, namespace, and dimensions.
Namespace
— (String
)The namespace of the metric. For more information, see Namespaces.
MetricName
— (String
)The name of the metric to use.
Dimensions
— (Array<map>
)An array of one or more dimensions to use to define the metric that you want to use. For more information, see Dimensions.
Name
— required — (String
)The name of the dimension. Dimension names must contain only ASCII characters, must include at least one non-whitespace character, and cannot start with a colon (
:
). ASCII control characters are not supported as part of dimension names.Value
— required — (String
)The value of the dimension. Dimension values must contain only ASCII characters and must include at least one non-whitespace character. ASCII control characters are not supported as part of dimension values.
Period
— required — (Integer
)The granularity, in seconds, to be used for the metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.Stat
— required — (String
)The statistic to use for comparison to the threshold. It can be any CloudWatch statistic or extended statistic. For more information about statistics, see CloudWatch statistics definitions.
Unit
— (String
)If you omit
Possible values include:Unit
then all data that was collected with any unit is returned, along with the corresponding units that were specified when the data was reported to CloudWatch. If you specify a unit, the operation returns only data that was collected with that unit specified. If you specify a unit that does not match the data collected, the results of the operation are null. CloudWatch does not perform unit conversions."Microseconds"
"Milliseconds"
"Seconds"
"Bytes"
"Kilobytes"
"Megabytes"
"Gigabytes"
"Terabytes"
"Bits"
"Kilobits"
"Megabits"
"Gigabits"
"Terabits"
"Percent"
"Count"
"Bytes/Second"
"Kilobytes/Second"
"Megabytes/Second"
"Gigabytes/Second"
"Terabytes/Second"
"Bits/Second"
"Kilobits/Second"
"Megabits/Second"
"Gigabits/Second"
"Terabits/Second"
"Count/Second"
"None"
Expression
— (String
)This field can contain a metric math expression to be performed on the other metrics that you are retrieving within this
MetricDataQueries
structure.A math expression can use the
Id
of the other metrics or queries to refer to those metrics, and can also use theId
of other expressions to use the result of those expressions. For more information about metric math expressions, see Metric Math Syntax and Functions in the Amazon CloudWatch User Guide.Within each
MetricDataQuery
object, you must specify eitherExpression
orMetricStat
but not both.Label
— (String
)A human-readable label for this metric or expression. This is especially useful if this is an expression, so that you know what the value represents. If the metric or expression is shown in a CloudWatch dashboard widget, the label is shown. If
Label
is omitted, CloudWatch generates a default.You can put dynamic expressions into a label, so that it is more descriptive. For more information, see Using Dynamic Labels.
ReturnData
— (Boolean
)Use this only if you are using a metric math expression for the SLO. Specify
true
forReturnData
for only the one expression result to use as the alarm. For all other metrics and expressions in the sameCreateServiceLevelObjective
operation, specifyReturnData
asfalse
.Period
— (Integer
)The granularity, in seconds, of the returned data points for this metric. For metrics with regular resolution, a period can be as short as one minute (60 seconds) and must be a multiple of 60. For high-resolution metrics that are collected at intervals of less than one minute, the period can be 1, 5, 10, 30, 60, or any multiple of 60. High-resolution metrics are those metrics stored by a
PutMetricData
call that includes aStorageResolution
of 1 second.If the
StartTime
parameter specifies a time stamp that is greater than 3 hours ago, you must specify the period as follows or no data points in that time range is returned:-
Start time between 3 hours and 15 days ago - Use a multiple of 60 seconds (1 minute).
-
Start time between 15 and 63 days ago - Use a multiple of 300 seconds (5 minutes).
-
Start time greater than 63 days ago - Use a multiple of 3600 seconds (1 hour).
-
AccountId
— (String
)The ID of the account where this metric is located. If you are performing this operation in a monitoring account, use this to specify which source account to retrieve this metric from.
MetricThreshold
— (Float
)This value is the threshold that the observed metric values of the SLI metric are compared to.
ComparisonOperator
— (String
)The arithmetic operation used when comparing the specified metric to the threshold.
Possible values include:"GreaterThanOrEqualTo"
"GreaterThan"
"LessThan"
"LessThanOrEqualTo"
EvaluationType
— (String
)Displays whether this is a period-based SLO or a request-based SLO.
Possible values include:"PeriodBased"
"RequestBased"
Goal
— required — (map
)This structure contains the attributes that determine the goal of an SLO. This includes the time period for evaluation and the attainment threshold.
Interval
— (map
)The time period used to evaluate the SLO. It can be either a calendar interval or rolling interval.
If you omit this parameter, a rolling interval of 7 days is used.
RollingInterval
— (map
)If the interval is a rolling interval, this structure contains the interval specifications.
DurationUnit
— required — (String
)Specifies the rolling interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each rolling interval. For example, if
Duration
is7
andDurationUnit
isDAY
, each rolling interval is seven days.
CalendarInterval
— (map
)If the interval is a calendar interval, this structure contains the interval specifications.
StartTime
— required — (Date
)The date and time when you want the first interval to start. Be sure to choose a time that configures the intervals the way that you want. For example, if you want weekly intervals starting on Mondays at 6 a.m., be sure to specify a start time that is a Monday at 6 a.m.
When used in a raw HTTP Query API, it is formatted as be epoch time in seconds. For example:
1698778057
As soon as one calendar interval ends, another automatically begins.
DurationUnit
— required — (String
)Specifies the calendar interval unit.
Possible values include:"MINUTE"
"HOUR"
"DAY"
"MONTH"
Duration
— required — (Integer
)Specifies the duration of each calendar interval. For example, if
Duration
is1
andDurationUnit
isMONTH
, each interval is one month, aligned with the calendar.
AttainmentGoal
— (Float
)The threshold that determines if the goal is being met.
If this is a period-based SLO, the attainment goal is the percentage of good periods that meet the threshold requirements to the total periods within the interval. For example, an attainment goal of 99.9% means that within your interval, you are targeting 99.9% of the periods to be in healthy state.
If this is a request-based SLO, the attainment goal is the percentage of requests that must be successful to meet the attainment goal.
If you omit this parameter, 99 is used to represent 99% as the attainment goal.
WarningThreshold
— (Float
)The percentage of remaining budget over total budget that you want to get warnings for. If you omit this parameter, the default of 50.0 is used.
-
(AWS.Response)
—
Returns: